diff --git a/resources/[housing]/ox_doorlock/LICENSE b/resources/[housing]/ox_doorlock/LICENSE new file mode 100644 index 000000000..f420446c3 --- /dev/null +++ b/resources/[housing]/ox_doorlock/LICENSE @@ -0,0 +1,659 @@ + GNU GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + Copyright (C) 2007 Free Software Foundation, Inc. + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The GNU General Public License is a free, copyleft license for +software and other kinds of works. + + The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things. + + To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they +know their rights. + + Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it. + + For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions. + + Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users. + + Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free. + + The precise terms and conditions for copying, distribution and +modification follow. + + TERMS AND CONDITIONS + + 0. Definitions. + + "This License" refers to version 3 of the GNU General Public License. + + "Copyright" also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks. + + "The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and +"recipients" may be individuals or organizations. + + To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a "modified version" of the +earlier work or a work "based on" the earlier work. + + A "covered work" means either the unmodified Program or a work based +on the Program. + + To "propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well. + + To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying. + + An interactive user interface displays "Appropriate Legal Notices" +to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion. + + 1. Source Code. + + The "source code" for a work means the preferred form of the work +for making modifications to it. "Object code" means any non-source +form of a work. + + A "Standard Interface" means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language. + + The "System Libraries" of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +"Major Component", in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it. + + The "Corresponding Source" for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work. + + The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source. + + The Corresponding Source for a work in source code form is that +same work. + + 2. Basic Permissions. + + All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law. + + You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you. + + Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary. + + 3. Protecting Users' Legal Rights From Anti-Circumvention Law. + + No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures. + + When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures. + + 4. Conveying Verbatim Copies. + + You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program. + + You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee. + + 5. Conveying Modified Source Versions. + + You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions: + + a) The work must carry prominent notices stating that you modified + it, and giving a relevant date. + + b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + "keep intact all notices". + + c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it. + + d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so. + + A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +"aggregate" if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate. + + 6. Conveying Non-Source Forms. + + You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways: + + a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange. + + b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge. + + c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b. + + d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements. + + e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d. + + A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work. + + A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, "normally used" refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product. + + "Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made. + + If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM). + + The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network. + + Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying. + + 7. Additional Terms. + + "Additional permissions" are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions. + + When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission. + + Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms: + + a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or + + b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or + + c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or + + d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or + + e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or + + f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors. + + All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying. + + If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms. + + Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way. + + 8. Termination. + + You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11). + + However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation. + + Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice. + + Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10. + + 9. Acceptance Not Required for Having Copies. + + You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so. + + 10. Automatic Licensing of Downstream Recipients. + + Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License. + + An "entity transaction" is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts. + + You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it. + + 11. Patents. + + A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's "contributor version". + + A contributor's "essential patent claims" are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, "control" includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License. + + Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version. + + In the following three paragraphs, a "patent license" is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To "grant" such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party. + + If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. "Knowingly relying" means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid. + + If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it. + + A patent license is "discriminatory" if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007. + + Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law. + + 12. No Surrender of Others' Freedom. + + If conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program. + + 13. Use with the GNU Affero General Public License. + + Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such. + + 14. Revised Versions of this License. + + The Free Software Foundation may publish revised and/or new versions of +the GNU General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + + Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU General +Public License "or any later version" applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation. + + If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program. + + Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version. + + 15. Disclaimer of Warranty. + + THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. Limitation of Liability. + + IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES. + + 17. Interpretation of Sections 15 and 16. + + If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +state the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + ox_doorlock + Copyright (C) 2022 + Linden + Luke + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + +Also add information on how to contact you by electronic and paper mail. + + The GNU General Public License does not permit incorporating your program +into proprietary programs. If your program is a subroutine library, you +may consider it more useful to permit linking proprietary applications with +the library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. But first, please read +. diff --git a/resources/[housing]/ox_doorlock/README.md b/resources/[housing]/ox_doorlock/README.md new file mode 100644 index 000000000..d0c872ad4 --- /dev/null +++ b/resources/[housing]/ox_doorlock/README.md @@ -0,0 +1,130 @@ +# Ox Doorlock + +Door management resource, with compatibility for ox_core, qb-core, and es_extended. +Successor to nui_doorlock with less scuff and more stuff. + +_The UI needs to be built - use the [latest release](https://github.com/overextended/ox_doorlock/releases/latest/download/ox_doorlock.zip) if you want to drag-n-drop._ + +## Dependencies + +### [oxmysql](https://github.com/overextended/oxmysql) + +Doors are stored in a database for ease-of-use and to allow data to be easily cleared or shared. + +mysql-async is no longer supported. + - does not support error-catching (pcall) + - people use older versions which do not support parameters as arrays + - it isn't maintained and has issues that will never be resolved + +### [ox_lib](https://github.com/overextended/ox_lib) (v2.3.0 or higher) + +Used for some UI elements (i.e. notifications, progress circle, input), and cache. + +### [ox_target](https://github.com/overextended/ox_target) (preferred) or [qtarget](https://github.com/overextended/qtarget) (deprecated) or [qb-target](https://github.com/qbcore-framework/qb-target) + +(Optional) Used for lockpicking. + +## Usage + +Use the `/doorlock` command to open the UI and enter the settings for your new door. +Once you confirm the settings, activate your targeting resource (typically LALT) to select the entity (or entities) to use. + +Adding any arguments after the command will open the closest door to you, to easily modify it. + +## Conversion + +Placing nui_doorlock config files into the `convert` folder will convert the data and insert it into the database. +Success is _not_ guaranteed if using a fork on nui_doorlock, like the qb version. + +## Client API + +- Use the closest door. Still performs server-side checks, so may fail. + +```lua +exports.ox_doorlock:useClosestDoor() +``` + +- Pick the lock of the closest door. Still performs server-side checks, so may fail. + +```lua +exports.ox_doorlock:pickClosestDoor() +``` + +## Server API + +- Get data for door + +```lua +local mrpd_locker_rooms = exports.ox_doorlock:getDoor(1) +local mrpd_locker_rooms = exports.ox_doorlock:getDoorFromName('mrpd locker rooms') +``` + +- Set door state (0: unlocked, 1: locked) + +```lua +TriggerEvent('ox_doorlock:setState', mrpd_locker_rooms.id, state) +``` + +- Listen for event when door is toggled + +```lua +AddEventHandler('ox_doorlock:stateChanged', function(source, doorId, state, usedItem) + if usedItem == 'trainticket' then + local xPlayer = ESX.GetPlayerFromId(source) + xPlayer.removeInventoryItem(usedItem, 1) + end +end) +``` + +## Door Settings + +### General + +- Door name + - Used to easily identify the door. +- Passcode + - Door can be unlocked by anybody by using the code or phrase. +- Autolock interval + - Door will be locked after x seconds. +- Interact distance + - Door can only be used when within x metres. +- Door rate + - Door movement speed for sliding/garage/automatic doors, or swinging doors when locked. +- Locked + - Sets the door as locked by default. +- Double + - Door is a set of two doors, controlled together. +- Automatic + - Sliding/garage/automatic door. +- Lockpick + - Door can be lockpicked when interacting with a targeting resource. +- Hide UI + - No indicators (i.e. icon, text) will display on the door. + +### Characters + +- Character Id + - Character identifier used by a framework (i.e. player.charid, xPlayer.identifier, Player.CitizenId). + +### Groups + +- Group + - Framework dependent, referring to jobs, gangs, etc. +- Grade + - The minimum grade to allow access for the group (0 to allow all). + +### Items + +- Item + - Name of the item. +- Metadata type + - Requires metadata support (i.e. ox_inventory) to check slot.metadata.type + +### Lockpick + +- Difficulty + - Sets the skillcheck difficulty (see [docs](https://overextended.github.io/docs/ox_lib/Interface/Client/skillcheck)). +- Area size + - Custom difficulty area size. +- Speed multiplier + - Custom difficulty idicator speed. diff --git a/resources/[housing]/ox_doorlock/audio/data/oxdoorlock_sounds.dat54.rel b/resources/[housing]/ox_doorlock/audio/data/oxdoorlock_sounds.dat54.rel new file mode 100644 index 000000000..d1229f2be Binary files /dev/null and b/resources/[housing]/ox_doorlock/audio/data/oxdoorlock_sounds.dat54.rel differ diff --git a/resources/[housing]/ox_doorlock/audio/data/oxdoorlock_sounds.dat54.rel.xml b/resources/[housing]/ox_doorlock/audio/data/oxdoorlock_sounds.dat54.rel.xml new file mode 100644 index 000000000..519e0a725 --- /dev/null +++ b/resources/[housing]/ox_doorlock/audio/data/oxdoorlock_sounds.dat54.rel.xml @@ -0,0 +1,145 @@ + + + + + dlc_oxdoorlock\oxdoorlock + + + + + button_remote_simple +
+ + + scripted +
+ dlc_oxdoorlock/oxdoorlock + button_remote + +
+ + + door_bolt_simple +
+ + + scripted +
+ dlc_oxdoorlock/oxdoorlock + door_bolt + +
+ + + metal_locker_simple +
+ + + scripted +
+ dlc_oxdoorlock/oxdoorlock + metal_locker + +
+ + + metallic_creak_simple +
+ + + scripted +
+ dlc_oxdoorlock/oxdoorlock + metallic_creak + +
+ + + + + + dlc_oxdoorlock_set +
+ +
+ + + button_remote + button_remote_directional + + + door_bolt + door_bolt_directional + + + metal_locker + metal_locker_directional + + + metallic_creak + metallic_creak_directional + + +
+ + + button_remote_directional +
+ + + scripted +
+ button_remote_simple + + + + + +
+ + + door_bolt_directional +
+ + + scripted +
+ door_bolt_simple + + + + + +
+ + + metal_locker_directional +
+ + + scripted +
+ metal_locker_simple + + + + + +
+ + + metallic_creak_directional +
+ + + scripted +
+ metallic_creak_simple + + + + + +
+
+
diff --git a/resources/[housing]/ox_doorlock/audio/dlc_oxdoorlock/oxdoorlock.awc b/resources/[housing]/ox_doorlock/audio/dlc_oxdoorlock/oxdoorlock.awc new file mode 100644 index 000000000..1b5ef2b83 Binary files /dev/null and b/resources/[housing]/ox_doorlock/audio/dlc_oxdoorlock/oxdoorlock.awc differ diff --git a/resources/[housing]/ox_doorlock/audio/dlc_oxdoorlock/oxdoorlock.awc.xml b/resources/[housing]/ox_doorlock/audio/dlc_oxdoorlock/oxdoorlock.awc.xml new file mode 100644 index 000000000..112836d25 --- /dev/null +++ b/resources/[housing]/ox_doorlock/audio/dlc_oxdoorlock/oxdoorlock.awc.xml @@ -0,0 +1,107 @@ + + + + + + + button_remote + button_remote.wav + + + peak + + + data + + + format + ADPCM + + + + + + + + + + + + + + door_bolt + door_bolt.wav + + + peak + + + data + + + format + ADPCM + + + + + + + + + + + + + + metal_locker + metal_locker.wav + + + peak + + + data + + + format + ADPCM + + + + + + + + + + + + + + metallic_creak + metallic_creak.wav + + + peak + + + data + + + format + ADPCM + + + + + + + + + + + + + + diff --git a/resources/[housing]/ox_doorlock/audio/dlc_oxdoorlock/oxdoorlock/button_remote.wav b/resources/[housing]/ox_doorlock/audio/dlc_oxdoorlock/oxdoorlock/button_remote.wav new file mode 100644 index 000000000..1bcd010c6 Binary files /dev/null and b/resources/[housing]/ox_doorlock/audio/dlc_oxdoorlock/oxdoorlock/button_remote.wav differ diff --git a/resources/[housing]/ox_doorlock/audio/dlc_oxdoorlock/oxdoorlock/door_bolt.wav b/resources/[housing]/ox_doorlock/audio/dlc_oxdoorlock/oxdoorlock/door_bolt.wav new file mode 100644 index 000000000..a27e3251c Binary files /dev/null and b/resources/[housing]/ox_doorlock/audio/dlc_oxdoorlock/oxdoorlock/door_bolt.wav differ diff --git a/resources/[housing]/ox_doorlock/audio/dlc_oxdoorlock/oxdoorlock/metal_locker.wav b/resources/[housing]/ox_doorlock/audio/dlc_oxdoorlock/oxdoorlock/metal_locker.wav new file mode 100644 index 000000000..dc640352c Binary files /dev/null and b/resources/[housing]/ox_doorlock/audio/dlc_oxdoorlock/oxdoorlock/metal_locker.wav differ diff --git a/resources/[housing]/ox_doorlock/audio/dlc_oxdoorlock/oxdoorlock/metallic_creak.wav b/resources/[housing]/ox_doorlock/audio/dlc_oxdoorlock/oxdoorlock/metallic_creak.wav new file mode 100644 index 000000000..a2bff3a93 Binary files /dev/null and b/resources/[housing]/ox_doorlock/audio/dlc_oxdoorlock/oxdoorlock/metallic_creak.wav differ diff --git a/resources/[housing]/ox_doorlock/client/main.lua b/resources/[housing]/ox_doorlock/client/main.lua new file mode 100644 index 000000000..778e4a8fa --- /dev/null +++ b/resources/[housing]/ox_doorlock/client/main.lua @@ -0,0 +1,349 @@ +if not LoadResourceFile(cache.resource, 'web/build/index.html') then + error('Unable to load UI. Build ox_doorlock or download the latest release.\n ^3https://github.com/overextended/ox_doorlock/releases/latest/download/ox_doorlock.zip^0') +end + +if not lib.checkDependency('ox_lib', '3.14.0', true) then return end + +local function createDoor(door) + local double = door.doors + door.zone = GetLabelText(GetNameOfZone(door.coords.x, door.coords.y, door.coords.z)) + + if double then + for i = 1, 2 do + AddDoorToSystem(double[i].hash, double[i].model, double[i].coords.x, double[i].coords.y, double[i].coords.z, false, false, false) + DoorSystemSetDoorState(double[i].hash, 4, false, false) + DoorSystemSetDoorState(double[i].hash, door.state, false, false) + + if door.doorRate or not door.auto then + DoorSystemSetAutomaticRate(double[i].hash, door.doorRate or 10.0, false, false) + end + end + else + AddDoorToSystem(door.hash, door.model, door.coords.x, door.coords.y, door.coords.z, false, false, false) + DoorSystemSetDoorState(door.hash, 4, false, false) + DoorSystemSetDoorState(door.hash, door.state, false, false) + + if door.doorRate or not door.auto then + DoorSystemSetAutomaticRate(door.hash, door.doorRate or 10.0, false, false) + end + end +end + +local nearbyDoors = {} +local Entity = Entity + +lib.callback('ox_doorlock:getDoors', false, function(data) + doors = data + + for _, door in pairs(data) do + createDoor(door) + end + + while true do + table.wipe(nearbyDoors) + local coords = GetEntityCoords(cache.ped) + + for _, door in pairs(doors) do + local double = door.doors + door.distance = #(coords - door.coords) + + if double then + if door.distance < 80 then + for i = 1, 2 do + if not double[i].entity and IsModelValid(double[i].model) then + local entity = GetClosestObjectOfType(double[i].coords.x, double[i].coords.y, double[i].coords.z, 1.0, double[i].model, false, false, false) + + if entity ~= 0 then + double[i].entity = entity + Entity(entity).state.doorId = door.id + end + end + end + + if door.distance < 20 then + nearbyDoors[#nearbyDoors + 1] = door + end + else + for i = 1, 2 do + double[i].entity = nil + end + end + elseif door.distance < 80 then + if not door.entity and IsModelValid(door.model) then + local entity = GetClosestObjectOfType(door.coords.x, door.coords.y, door.coords.z, 1.0, door.model, false, false, false) + + if entity ~= 0 then + local min, max = GetModelDimensions(door.model) + local points = { + GetOffsetFromEntityInWorldCoords(entity, min.x, min.y, min.z).xy, + GetOffsetFromEntityInWorldCoords(entity, min.x, min.y, max.z).xy, + GetOffsetFromEntityInWorldCoords(entity, min.x, max.y, max.z).xy, + GetOffsetFromEntityInWorldCoords(entity, min.x, max.y, min.z).xy, + GetOffsetFromEntityInWorldCoords(entity, max.x, min.y, min.z).xy, + GetOffsetFromEntityInWorldCoords(entity, max.x, min.y, max.z).xy, + GetOffsetFromEntityInWorldCoords(entity, max.x, max.y, max.z).xy, + GetOffsetFromEntityInWorldCoords(entity, max.x, max.y, min.z).xy + } + + local centroid = vec2(0, 0) + + for i = 1, 8 do + centroid += points[i] + end + + centroid = centroid / 8 + door.coords = vec3(centroid.x, centroid.y, door.coords.z) + door.entity = entity + Entity(entity).state.doorId = door.id + end + end + + if door.distance < 20 then + nearbyDoors[#nearbyDoors + 1] = door + end + elseif door.entity then + door.entity = nil + end + end + + Wait(500) + end +end) + +RegisterNetEvent('ox_doorlock:setState', function(id, state, source, data) + if not doors then return end + + if data then + doors[id] = data + createDoor(data) + + if NuiHasLoaded then + SendNuiMessage(json.encode({ + action = 'updateDoorData', + data = data + })) + end + end + + if Config.Notify and source == cache.serverId then + if state == 0 then + lib.notify({ + type = 'success', + icon = 'unlock', + description = locale('unlocked_door') + }) + else + lib.notify({ + type = 'success', + icon = 'lock', + description = locale('locked_door') + }) + end + end + + local door = data or doors[id] + local double = door.doors + door.state = state + + if double then + DoorSystemSetDoorState(double[1].hash, door.state, false, false) + DoorSystemSetDoorState(double[2].hash, door.state, false, false) + + if door.holdOpen then + DoorSystemSetHoldOpen(double[1].hash, door.state == 0) + DoorSystemSetHoldOpen(double[2].hash, door.state == 0) + end + + while door.state == 1 and (not IsDoorClosed(double[1].hash) or not IsDoorClosed(double[2].hash)) do Wait(0) end + else + DoorSystemSetDoorState(door.hash, door.state, false, false) + + if door.holdOpen then DoorSystemSetHoldOpen(door.hash, door.state == 0) end + while door.state == 1 and not IsDoorClosed(door.hash) do Wait(0) end + end + + if door.state == state and door.distance and door.distance < 20 then + if Config.NativeAudio then + RequestScriptAudioBank('dlc_oxdoorlock/oxdoorlock', false) + local sound = state == 0 and door.unlockSound or door.lockSound or 'door_bolt' + local soundId = GetSoundId() + + PlaySoundFromCoord(soundId, sound, door.coords.x, door.coords.y, door.coords.z, 'DLC_OXDOORLOCK_SET', false, 0, false) + ReleaseSoundId(soundId) + ReleaseNamedScriptAudioBank('dlc_oxdoorlock/oxdoorlock') + else + local volume = (0.01 * GetProfileSetting(300)) / (door.distance / 2) + if volume > 1 then volume = 1 end + local sound = state == 0 and door.unlockSound or door.lockSound or 'door-bolt-4' + + SendNUIMessage({ + action = 'playSound', + data = { + sound = sound, + volume = volume + } + }) + end + end +end) + +RegisterNetEvent('ox_doorlock:editDoorlock', function(id, data) + if source == '' then return end + + local door = doors[id] + local double = door.doors + local doorState = data and data.state or 0 + + if data then + data.zone = door.zone or GetLabelText(GetNameOfZone(door.coords.x, door.coords.y, door.coords.z)) + + -- hacky method to resolve a bug with "closest door" by forcing a distance recalculation + if door.distance < 20 then door.distance = 80 end + elseif ClosestDoor?.id == id then + ClosestDoor = nil + end + + if double then + for i = 1, 2 do + local doorHash = double[i].hash + + if data then + if data.doorRate or door.doorRate or not data.auto then + DoorSystemSetAutomaticRate(doorHash, data.doorRate or door.doorRate and 0.0 or 10.0, false, false) + end + + DoorSystemSetDoorState(doorHash, doorState, false, false) + + if data.holdOpen then DoorSystemSetHoldOpen(doorHash, doorState == 0) end + else + DoorSystemSetDoorState(doorHash, 4, false, false) + DoorSystemSetDoorState(doorHash, 0, false, false) + + if double[i].entity then + Entity(double[i].entity).state.doorId = nil + end + end + end + else + if data then + if data.doorRate or door.doorRate or not data.auto then + DoorSystemSetAutomaticRate(door.hash, data.doorRate or door.doorRate and 0.0 or 10.0, false, false) + end + + DoorSystemSetDoorState(door.hash, doorState, false, false) + + if data.holdOpen then DoorSystemSetHoldOpen(door.hash, doorState == 0) end + else + DoorSystemSetDoorState(door.hash, 4, false, false) + DoorSystemSetDoorState(door.hash, 0, false, false) + + if door.entity then + Entity(door.entity).state.doorId = nil + end + end + end + + doors[id] = data + + if NuiHasLoaded then + SendNuiMessage(json.encode({ + action = 'updateDoorData', + data = data or id + })) + end +end) + +ClosestDoor = nil + +lib.callback.register('ox_doorlock:inputPassCode', function() + return ClosestDoor?.passcode and lib.inputDialog(locale('door_lock'), { + { + type = 'input', + label = locale('passcode'), + password = true, + icon = 'lock' + }, + })?[1] +end) + +local lastTriggered = 0 + +local function useClosestDoor() + if not ClosestDoor then return false end + + local gameTimer = GetGameTimer() + + if gameTimer - lastTriggered > 500 then + lastTriggered = gameTimer + TriggerServerEvent('ox_doorlock:setState', ClosestDoor.id, ClosestDoor.state == 1 and 0 or 1) + end +end + +exports('useClosestDoor', useClosestDoor) + +CreateThread(function() + local lockDoor = locale('lock_door') + local unlockDoor = locale('unlock_door') + local showUI + local drawSprite = Config.DrawSprite + + if drawSprite then + local sprite1 = drawSprite[0]?[1] + local sprite2 = drawSprite[1]?[1] + + if sprite1 then + RequestStreamedTextureDict(sprite1, true) + end + + if sprite2 then + RequestStreamedTextureDict(sprite2, true) + end + end + + local SetDrawOrigin = SetDrawOrigin + local ClearDrawOrigin = ClearDrawOrigin + local DrawSprite = drawSprite and DrawSprite + + while true do + local num = #nearbyDoors + + if num > 0 then + local ratio = drawSprite and GetAspectRatio(true) + for i = 1, num do + local door = nearbyDoors[i] + + if door.distance < door.maxDistance then + if door.distance < (ClosestDoor?.distance or 10) then + ClosestDoor = door + end + + if drawSprite and not door.hideUi then + local sprite = drawSprite[door.state] + + if sprite then + SetDrawOrigin(door.coords.x, door.coords.y, door.coords.z) + DrawSprite(sprite[1], sprite[2], sprite[3], sprite[4], sprite[5], sprite[6] * ratio, sprite[7], sprite[8], sprite[9], sprite[10], sprite[11]) + ClearDrawOrigin() + end + end + end + end + else ClosestDoor = nil end + + if ClosestDoor and ClosestDoor.distance < ClosestDoor.maxDistance then + if Config.DrawTextUI and not ClosestDoor.hideUi and ClosestDoor.state ~= showUI then + lib.showTextUI(ClosestDoor.state == 0 and lockDoor or unlockDoor) + showUI = ClosestDoor.state + end + + if not PickingLock and IsDisabledControlJustReleased(0, 38) then + useClosestDoor() + end + elseif showUI then + lib.hideTextUI() + showUI = nil + end + + Wait(num > 0 and 0 or 500) + end +end) diff --git a/resources/[housing]/ox_doorlock/client/utils.lua b/resources/[housing]/ox_doorlock/client/utils.lua new file mode 100644 index 000000000..cdbec57d0 --- /dev/null +++ b/resources/[housing]/ox_doorlock/client/utils.lua @@ -0,0 +1,410 @@ +local Entity = Entity + +local function getDoorFromEntity(data) + local entity = type(data) == 'table' and data.entity or data + + if not entity then return end + + local state = Entity(entity)?.state + local doorId = state?.doorId + + if not doorId then return end + + local door = doors[doorId] + + if not door then + state.doorId = nil + end + + return door +end + +exports('getClosestDoorId', function() return ClosestDoor?.id end) +exports('getDoorIdFromEntity', function(entityId) return getDoorFromEntity(entityId)?.id end) -- same as Entity(entityId).state.doorId + +local function entityIsNotDoor(data) + local entity = type(data) == 'number' and data or data.entity + return not getDoorFromEntity(entity) +end + +PickingLock = false + +local function canPickLock(entity) + if PickingLock then return false end + + local door = getDoorFromEntity(entity) + + return door and door.lockpick and (Config.CanPickUnlockedDoors or door.state == 1) +end + +---@param entity number +local function pickLock(entity) + local door = getDoorFromEntity(entity) + + if not door or PickingLock or not door.lockpick or (not Config.CanPickUnlockedDoors and door.state == 0) then return end + + PickingLock = true + + TaskTurnPedToFaceCoord(cache.ped, door.coords.x, door.coords.y, door.coords.z, 4000) + Wait(500) + + local animDict = lib.requestAnimDict('mp_common_heist') + + TaskPlayAnim(cache.ped, animDict, 'pick_door', 3.0, 1.0, -1, 49, 0, true, true, true) + + local success = lib.skillCheck(door.lockpickDifficulty or Config.LockDifficulty) + local rand = math.random(1, success and 100 or 5) + + if success then + TriggerServerEvent('ox_doorlock:setState', door.id, door.state == 1 and 0 or 1, true) + end + + if rand == 1 then + TriggerServerEvent('ox_doorlock:breakLockpick') + lib.notify({ type = 'error', description = locale('lockpick_broke') }) + end + + StopEntityAnim(cache.ped, 'pick_door', animDict, 0) + RemoveAnimDict(animDict) + + PickingLock = false +end + +exports('pickClosestDoor', function() + if not ClosestDoor then return end + + pickLock(ClosestDoor.entity) +end) + +local tempData = {} + +local function addDoorlock(data) + local entity = type(data) == 'number' and data or data.entity + local model = GetEntityModel(entity) + local coords = GetEntityCoords(entity) + + AddDoorToSystem(`temp`, model, coords.x, coords.y, coords.z, false, false, false) + DoorSystemSetDoorState(`temp`, 4, false, false) + + coords = GetEntityCoords(entity) + tempData[#tempData + 1] = { + entity = entity, + model = model, + coords = coords, + heading = math.floor(GetEntityHeading(entity) + 0.5) + } + + RemoveDoorFromSystem(`temp`) +end + +local isAddingDoorlock = false + +RegisterNUICallback('notify', function(data, cb) + cb(1) + lib.notify({ title = data }) +end) + +RegisterNUICallback('createDoor', function(data, cb) + cb(1) + SetNuiFocus(false, false) + + data.state = data.state and 1 or 0 + + if data.items and not next(data.items) then + data.items = nil + end + + if data.characters and not next(data.characters) then + data.characters = nil + end + + if data.lockpickDifficulty and not next(data.lockpickDifficulty) then + data.lockpickDifficulty = nil + end + + if data.groups and not next(data.groups) then + data.groups = nil + end + + if not data.id then + isAddingDoorlock = true + local doorCount = data.doors and 2 or 1 + local lastEntity = 0 + + lib.showTextUI(locale('add_door_textui')) + + repeat + DisablePlayerFiring(cache.playerId, true) + DisableControlAction(0, 25, true) + + local hit, entity, coords = lib.raycast.cam(1|16) + local changedEntity = lastEntity ~= entity + local doorA = tempData[1]?.entity + + if changedEntity and lastEntity ~= doorA then + SetEntityDrawOutline(lastEntity, false) + end + + lastEntity = entity + + if hit then + ---@diagnostic disable-next-line: param-type-mismatch + DrawMarker(28, coords.x, coords.y, coords.z, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.2, 0.2, 0.2, 255, 42, 24, + 100, false, false, 0, true, false, false, false) + end + + if hit and entity > 0 and GetEntityType(entity) == 3 and (doorCount == 1 or doorA ~= entity) and entityIsNotDoor(entity) then + if changedEntity then + SetEntityDrawOutline(entity, true) + end + + if IsDisabledControlJustPressed(0, 24) then + addDoorlock(entity) + end + end + + if IsDisabledControlJustPressed(0, 25) then + SetEntityDrawOutline(entity, false) + + if not doorA then + isAddingDoorlock = false + return lib.hideTextUI() + end + + SetEntityDrawOutline(doorA, false) + table.wipe(tempData) + end + until tempData[doorCount] + + lib.hideTextUI() + SetEntityDrawOutline(tempData[1].entity, false) + + if data.doors then + SetEntityDrawOutline(tempData[2].entity, false) + tempData[1].entity = nil + tempData[2].entity = nil + data.doors = tempData + else + data.model = tempData[1].model + data.coords = tempData[1].coords + data.heading = tempData[1].heading + end + else + if data.doors then + for i = 1, 2 do + local coords = data.doors[i].coords + data.doors[i].coords = vector3(coords.x, coords.y, coords.z) + data.doors[i].entity = nil + end + else + data.entity = nil + end + + data.coords = vector3(data.coords.x, data.coords.y, data.coords.z) + data.distance = nil + data.zone = nil + end + + isAddingDoorlock = false + + ------------------------------------ + ------- Brutal Housing Editing ----- + ------------------------------------ + if PropertyID ~= nil then + if data.name:match("^(.-)_") == nil or data.name:match("^(.-)_") ~= PropertyID then + data.name = PropertyID.."_"..data.name + end + + local coords = data.coords or data.doors[1].coords + if coords ~= nil then + if #(coords - vector3(PropertyCoords.x, PropertyCoords.y, PropertyCoords.z)) > MaxDoorlockDistance then + TriggerEvent('brutal_housing:client:SendNotifyNumber', 75) + return + end + else + return + end + + PropertyID = nil + PropertyCoords = nil + end + ------------------------------------ + ------- Brutal Housing Editing ----- + ------------------------------------ + + TriggerServerEvent('ox_doorlock:editDoorlock', data.id or false, data) + table.wipe(tempData) +end) + +RegisterNUICallback('deleteDoor', function(id, cb) + cb(1) + TriggerServerEvent('ox_doorlock:editDoorlock', id) +end) + +RegisterNUICallback('teleportToDoor', function(id, cb) + cb(1) + SetNuiFocus(false, false) + local doorCoords = doors[id].coords + if not doorCoords then return end + SetEntityCoords(cache.ped, doorCoords.x, doorCoords.y, doorCoords.z, false, false, false, false) +end) + +RegisterNUICallback('exit', function(_, cb) + cb(1) + SetNuiFocus(false, false) +end) + +------------------------------------ +------- Brutal Housing Editing ----- +------------------------------------ + +PropertyID = nil +PropertyCoords = nil +MaxDoorlockDistance = 50.0 + +RegisterNetEvent("ox_doorlock:dataFromHousing") +AddEventHandler("ox_doorlock:dataFromHousing", function(propertyID, coords, maxdoorlockdistance) + PropertyID = propertyID + PropertyCoords = coords + MaxDoorlockDistance = maxdoorlockdistance + + if isAddingDoorlock then return end + + NuiHasLoaded = true + + local allowedDoors = {} + for k,v in pairs(doors) do + print(v.name:match("^(.-)_"), PropertyID) + if v.name:match("^(.-)_") == PropertyID then + table.insert(allowedDoors, v) + end + end + + SendNuiMessage(json.encode({ + action = 'updateDoorData', + data = allowedDoors + }, { with_hole = false })) + Wait(100) + + SendNUIMessage({ + action = 'setSoundFiles', + data = lib.callback.await('ox_doorlock:getSounds', false) + }) + + SetNuiFocus(true, true) + SendNuiMessage(json.encode({ + action = 'setVisible', + data = id + })) +end) + +------------------------------------ +------- Brutal Housing Editing ----- +------------------------------------ + +local function openUi(id) + if source == '' or isAddingDoorlock then return end + + ------------------------------------ + ------- Brutal Housing Editing ----- + ------------------------------------ + PropertyID = nil + PropertyCoords = nil + ------------------------------------ + ------- Brutal Housing Editing ----- + ------------------------------------ + + NuiHasLoaded = true + + SendNuiMessage(json.encode({ + action = 'updateDoorData', + data = doors + }, { with_hole = false })) + Wait(100) + + SendNUIMessage({ + action = 'setSoundFiles', + data = lib.callback.await('ox_doorlock:getSounds', false) + }) + + SetNuiFocus(true, true) + SendNuiMessage(json.encode({ + action = 'setVisible', + data = id + })) +end + +RegisterNetEvent('ox_doorlock:triggeredCommand', function(closest) + openUi(closest and ClosestDoor?.id or nil) +end) + +CreateThread(function() + local target + + if GetResourceState('ox_target'):find('start') then + target = { + ox = true, + exp = exports.ox_target + } + elseif GetResourceState('qb-target'):find('start') then + target = { + qb = true, + exp = exports['qb-target'] + } + elseif GetResourceState('qtarget'):find('start') then + target = { + qt = true, + exp = exports.qtarget + } + end + + if not target then return end + + if target.ox then + target.exp:addGlobalObject({ + { + name = 'pickDoorlock', + label = locale('pick_lock'), + icon = 'fas fa-user-lock', + onSelect = pickLock, + canInteract = canPickLock, + items = Config.LockpickItems, + anyItem = true, + distance = 1 + } + }) + else + local options = { + { + label = locale('pick_lock'), + icon = 'fas fa-user-lock', + action = pickLock, + canInteract = canPickLock, + item = Config.LockpickItems[1], + distance = 1 + } + } + + ---@cast target table + + if target.qt then + target.exp:Object({ options = options }) + elseif target.qb then + target.exp:AddGlobalObject({ options = options }) + end + + options = { locale('pick_lock') } + + AddEventHandler('onResourceStop', function(resource) + if resource == cache.resource then + if target.qt then + return target.exp:RemoveObject(options) + end + + if target.qb then + return target.exp:RemoveGlobalObject(options) + end + end + end) + end +end) diff --git a/resources/[housing]/ox_doorlock/config.lua b/resources/[housing]/ox_doorlock/config.lua new file mode 100644 index 000000000..8d432c300 --- /dev/null +++ b/resources/[housing]/ox_doorlock/config.lua @@ -0,0 +1,38 @@ +---@type DoorlockConfig +---@diagnostic disable-next-line: missing-fields +Config = {} + +---Trigger a notification on the client when the door state is successfully updated. +Config.Notify = false + +---Create a persistent notification while in-range of a door, prompting to lock/unlock. +Config.DrawTextUI = false + +---Set the properties used by [DrawSprite](https://docs.fivem.net/natives/?_0xE7FFAE5EBF23D890). +Config.DrawSprite = { + -- Unlocked + [0] = { 'mpsafecracking', 'lock_open', 0, 0, 0.018, 0.018, 0, 255, 255, 255, 100 }, + + -- Locked + [1] = { 'mpsafecracking', 'lock_closed', 0, 0, 0.018, 0.018, 0, 255, 255, 255, 100 }, +} + +---Allow the specified ace principal to use 'command.doorlock'. +Config.CommandPrincipal = 'group.admin' + +---Allow players with the 'command.doorlock' principal to use any door. +Config.PlayerAceAuthorised = false + +---The default skill check difficulty when lockpicking a door. +Config.LockDifficulty = { 'easy', 'easy', 'medium' } + +---Allow lockpicks to be used to lock an unlocked door. +Config.CanPickUnlockedDoors = false + +---An array of items that function as lockpicks. +Config.LockpickItems = { + 'lockpick' +} + +---Play sounds using game audio (sound natives) instead of through NUI. +Config.NativeAudio = true diff --git a/resources/[housing]/ox_doorlock/fxmanifest.lua b/resources/[housing]/ox_doorlock/fxmanifest.lua new file mode 100644 index 000000000..51986fa31 --- /dev/null +++ b/resources/[housing]/ox_doorlock/fxmanifest.lua @@ -0,0 +1,51 @@ +--[[ FX Information ]]-- +fx_version 'cerulean' +use_experimental_fxv2_oal 'yes' +lua54 'yes' +game 'gta5' + +--[[ Resource Information ]]-- +name 'ox_doorlock' +version '1.17.0' +license 'GPL-3.0-or-later' +author 'Overextended' +repository 'https://github.com/overextended/ox_doorlock' + +--[[ Manifest ]]-- +shared_scripts { + '@ox_lib/init.lua', + 'config.lua', +} + +client_scripts { + 'client/main.lua', + 'client/utils.lua', +} + +server_scripts { + '@oxmysql/lib/MySQL.lua', + 'server/main.lua', +} + +ui_page 'web/build/index.html' + +files { + 'web/build/index.html', + 'web/build/**/*', + 'locales/*.json', + 'audio/data/oxdoorlock_sounds.dat54.rel', + 'audio/dlc_oxdoorlock/oxdoorlock.awc', +} + +data_file 'AUDIO_WAVEPACK' 'audio/dlc_oxdoorlock' +data_file 'AUDIO_SOUNDDATA' 'audio/data/oxdoorlock_sounds.dat' + +dependencies { + 'oxmysql', + 'ox_lib', +} + +ox_libs { + 'locale', + 'table', +} diff --git a/resources/[housing]/ox_doorlock/locales/ar.json b/resources/[housing]/ox_doorlock/locales/ar.json new file mode 100644 index 000000000..48ea143bf --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/ar.json @@ -0,0 +1,19 @@ +{ + "unlocked_door": "الباب مفتوح", + "locked_door": "الباب مغلق", + "lock_door": "[E] غلق", + "unlock_door": "[E] فتح", + "door_lock": "قفل الباب", + "passcode": "الكود", + "lockpick_broke": "المفك مكسور", + "pick_lock": "حصل مفتاح", + "add_lock": "إضافة باب", + "edit_lock": "تعديل باب", + "remove_lock": "حدف باب", + "cannot_unlock": "غير ممكن", + "cannot_lock": "غير ممكن", + "create_modify_lock": "إنشاء أو تعديل قفل باب", + "add_door_textui": "**إنشاء باب جديد** \n[LMB] للتأكيد إضغط \n[RMB] للإلغاء إضغط", + "command_closest": "إنشاء قفل أو التفعل مع أقرب باب" + } + diff --git a/resources/[housing]/ox_doorlock/locales/cs.json b/resources/[housing]/ox_doorlock/locales/cs.json new file mode 100644 index 000000000..ee44850c7 --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/cs.json @@ -0,0 +1,18 @@ +{ + "unlocked_door": "Dveře odemčeny", + "locked_door": "Dveře zamčeny", + "lock_door": "[E] Zamknout dveře", + "unlock_door": "[E] Odemknout dveře", + "door_lock": "Zámek dveří", + "passcode": "Přístupový kód", + "lockpick_broke": "Šperhák se zlomil", + "pick_lock": "Vypáčit zámek", + "add_lock": "Přidat zámek", + "edit_lock": "Upravit zámek", + "remove_lock": "Odebrat zámek", + "cannot_unlock": "Nelze odemknout dveře", + "cannot_lock": "Nelze zamknout dveře", + "create_modify_lock": "Vytvořit zámek, nebo upravit existující", + "add_door_textui": "**Vytvořit nový zámek** \nPokračovat pomocí [LMB] \nZrušit pomocí [RMB]", + "command_closest": "Otevřít UI pro nejbližší zámek" +} diff --git a/resources/[housing]/ox_doorlock/locales/de.json b/resources/[housing]/ox_doorlock/locales/de.json new file mode 100644 index 000000000..4036052c2 --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/de.json @@ -0,0 +1,18 @@ +{ + "unlocked_door": "Tür aufgeschlossen", + "locked_door": "Tür verschlossen", + "lock_door": "[E] Tür verschließen", + "unlock_door": "[E] Tür aufschließen", + "door_lock": "Türschloss", + "passcode": "Zugangscode", + "lockpick_broke": "Dein Dietrich ist zerbrochen", + "pick_lock": "Tür aufbrechen", + "add_lock": "Türschloss hinzufügen", + "edit_lock": "Türschloss bearbeiten", + "remove_lock": "Türschloss entfernen", + "cannot_unlock": "Es ist nicht möglich die Tür aufzuschließen", + "cannot_lock": "Es ist nicht möglich die Tür zu verschließen", + "create_modify_lock": "Erstelle ein Türschloss oder bearbeite ein vorhandenes", + "add_door_textui": "Neue Tür erstellen \nMit [LMB] interagieren \nMit [RMB] abbrechen", + "command_closest": "Öffne die UI direkt zur nächstgelegenen Tür" +} diff --git a/resources/[housing]/ox_doorlock/locales/en.json b/resources/[housing]/ox_doorlock/locales/en.json new file mode 100644 index 000000000..227a9699a --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/en.json @@ -0,0 +1,18 @@ +{ + "unlocked_door": "Unlocked door", + "locked_door": "Locked door", + "lock_door": "[E] Lock door", + "unlock_door": "[E] Unlock door", + "door_lock": "Door lock", + "passcode": "Passcode", + "lockpick_broke": "Your lockpick broke", + "pick_lock": "Pick lock", + "add_lock": "Add doorlock", + "edit_lock": "Edit doorlock", + "remove_lock": "Remove doorlock", + "cannot_unlock": "Unable to unlock door", + "cannot_lock": "Unable to lock door", + "create_modify_lock": "Create a doorlock, or modify an existing one", + "add_door_textui": "**Create new door** \nInteract with [LMB] \nCancel with [RMB]", + "command_closest": "Open UI directly to closest doorlock" +} diff --git a/resources/[housing]/ox_doorlock/locales/es.json b/resources/[housing]/ox_doorlock/locales/es.json new file mode 100644 index 000000000..65074dfa4 --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/es.json @@ -0,0 +1,16 @@ +{ + "unlocked_door": "Abierto", + "locked_door": "Cerrado", + "lock_door": "[E] Cerrar", + "unlock_door": "[E] Abrir", + "door_lock": "Bloqueo de Puertas", + "passcode": "PIN", + "lockpick_broke": "Se ha roto tu ganzúa", + "pick_lock": "Forzar", + "add_lock": "Añadir cerradura", + "edit_lock": "Editar cerradura", + "remove_lock": "Borrar cerradura", + "cannot_unlock": "No se puede abrir la cerradura", + "cannot_lock": "No se puede cerrar la cerradura", + "create_modify_lock": "Crear una cerradura o modificar una existente" +} diff --git a/resources/[housing]/ox_doorlock/locales/et.json b/resources/[housing]/ox_doorlock/locales/et.json new file mode 100644 index 000000000..ebcf4fd5a --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/et.json @@ -0,0 +1,18 @@ +{ + "unlocked_door": "Avatud", + "locked_door": "Lukustatud", + "lock_door": "[E] Lukusta uks", + "unlock_door": "[E] Ava uks", + "door_lock": "Ukselukk", + "passcode": "Parool", + "lockpick_broke": "Sinu muukraud murdus", + "pick_lock": "Murra ukselukk lahti", + "add_lock": "Lisa ukselukk", + "edit_lock": "Muuda ukselukku", + "remove_lock": "Eemalda ukselukk", + "cannot_unlock": "Sa ei saa seda avada..", + "cannot_lock": "Sa ei saa seda lukustada..", + "create_modify_lock": "Lisa uus ukselukk või muuda eelmiseid", + "add_door_textui": "**Lisa uus ukselukk** \nKasuta [LMB] \nKatkesta [RMB]", + "command_closest": "Ava lähima ukse UI" +} diff --git a/resources/[housing]/ox_doorlock/locales/fi.json b/resources/[housing]/ox_doorlock/locales/fi.json new file mode 100644 index 000000000..6371a7938 --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/fi.json @@ -0,0 +1,18 @@ +{ + "unlocked_door": "Ovi avattu", + "locked_door": "Ovi lukittu", + "lock_door": "[E] Lukitse ovi", + "unlock_door": "[E] Avaa ovi", + "door_lock": "Ovilukko", + "passcode": "Salasana", + "lockpick_broke": "Tiirikka hajosi", + "pick_lock": "Tiirikoi lukko", + "add_lock": "Lisää ovilukko", + "edit_lock": "Muokkaa ovilukkoa", + "remove_lock": "Poista ovilukko", + "cannot_unlock": "Et voi avata ovea", + "cannot_lock": "Et voi lukita ovea", + "create_modify_lock": "Luo ovilukko, tai muokkaa olemassaolevaa lukkoa", + "add_door_textui": "**Aseta Uusi Lukko** \nAseta [LMB] \nPeruuta [RMB]", + "command_closest": "Avaa ovilukko valikko lähimmästä ovesta" +} diff --git a/resources/[housing]/ox_doorlock/locales/fr.json b/resources/[housing]/ox_doorlock/locales/fr.json new file mode 100644 index 000000000..e64bd58ff --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/fr.json @@ -0,0 +1,17 @@ +{ + "unlocked_door": "Porte déverrouillée", + "locked_door": "Porte verrouillée", + "lock_door": "[E] Verrouiller la porte", + "unlock_door": "[E] Déverrouiller la porte", + "door_lock": "Verrou de porte", + "passcode": "Mot de passe", + "lockpick_broke": "Votre crochet s'est cassé", + "pick_lock": "Crocheter la serrure", + "add_lock": "Ajouter une serrure", + "edit_lock": "Modifier la serrure", + "remove_lock": "Retirer la serrure", + "cannot_unlock": "Impossible de déverrouiller la porte", + "cannot_lock": "Impossible de verrouiller la porte", + "create_modify_lock": "Ajouter / Modifier une serrure", + "add_door_textui": "**Créer une porte** \nIntéragir avec [LMB] \nAnnuler avec [RMB]" +} diff --git a/resources/[housing]/ox_doorlock/locales/hr.json b/resources/[housing]/ox_doorlock/locales/hr.json new file mode 100644 index 000000000..299164b0f --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/hr.json @@ -0,0 +1,16 @@ +{ + "unlocked_door": "Otključana vrata", + "locked_door": "Zaključana vrata", + "lock_door": "[E] Zaključaj vrata", + "unlock_door": "[E] Otključaj vrata", + "door_lock": "Lokot", + "passcode": "Lozinka", + "lockpick_broke": "Polomila Vam se brava", + "pick_lock": "Odaberi bravu", + "add_lock": "Dodaj lokot", + "edit_lock": "Uredi lokot", + "remove_lock": "Obriši lokot", + "cannot_unlock": "Nije moguće otključati vrata", + "cannot_lock": "Nije moguće zaključati vrata", + "create_modify_lock": "Dodaj lokot na vrata ili uredi postojeći" +} diff --git a/resources/[housing]/ox_doorlock/locales/hu.json b/resources/[housing]/ox_doorlock/locales/hu.json new file mode 100644 index 000000000..bf0e2eebd --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/hu.json @@ -0,0 +1,18 @@ +{ + "unlocked_door": "Ajtó kinyitva", + "locked_door": "Ajtó bezárva", + "lock_door": "[E] Bezárás", + "unlock_door": "[E] Kinyitás", + "door_lock": "Ajtózár", + "passcode": "Jelszó", + "lockpick_broke": "A zárfeltörőd eltört", + "pick_lock": "Zárfeltörés", + "add_lock": "Ajtózár hozzáadása", + "edit_lock": "Ajtózár szerkesztése", + "remove_lock": "Ajtózár törlése", + "cannot_unlock": "Nem tudtad kinyitni az ajtót", + "cannot_lock": "Nem tudtad bezárni az ajtót", + "create_modify_lock": "Készíts vagy szerkessz egy ajtózárat.", + "add_door_textui": "**Ajtó létrehozása** \nKiválaszt [LMB] \nMégse [RMB]", + "command_closest": "UI megnyitása közvetlenül a legközelebbi ajtózárhoz" +} diff --git a/resources/[housing]/ox_doorlock/locales/it.json b/resources/[housing]/ox_doorlock/locales/it.json new file mode 100644 index 000000000..3ce6552b0 --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/it.json @@ -0,0 +1,18 @@ +{ + "unlocked_door": "Porta sbloccata", + "locked_door": "Porta chiusa", + "lock_door": "[E] Chiudi porta", + "unlock_door": "[E] Apri porta", + "door_lock": "Serratura della porta", + "passcode": "codice di accesso", + "lockpick_broke": "il tuo grimaldello si è rotto", + "pick_lock": "Scassina serratura", + "add_lock": "Aggiungi serratura", + "edit_lock": "Modifica serratura", + "remove_lock": "Rimuovi serratura", + "cannot_unlock": "Impossibile aprire la porta", + "cannot_lock": "Impossibile chiudere la porta", + "create_modify_lock": "Crea una serratura o modificane una esistente", + "add_door_textui": "**Crea una nuova porta** \nInteragire con [LMB] \nAnnulla con [RMB]", + "command_closest": "Apri l'interfaccia utente direttamente alla serratura più vicina" +} diff --git a/resources/[housing]/ox_doorlock/locales/lt.json b/resources/[housing]/ox_doorlock/locales/lt.json new file mode 100644 index 000000000..90879d1c9 --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/lt.json @@ -0,0 +1,18 @@ +{ + "unlocked_door": "Durys atrakintos", + "locked_door": "Durys užrakintos", + "lock_door": "[E] Užrakinti duris", + "unlock_door": "[E] Atrakinti duris", + "door_lock": "Durų užraktas", + "passcode": "Slaptažodis", + "lockpick_broke": "Tavo įsilaužimo įrankis sulūžo", + "pick_lock": "Įsilaužti", + "add_lock": "Pridėti užraktą", + "edit_lock": "Redaguoti užraktą", + "remove_lock": "Panaikinti užraktą", + "cannot_unlock": "Durų atidaryti nepavyko", + "cannot_lock": "Durų užrakinti nepavyko", + "create_modify_lock": "Sukurk naują durų užraktą, arba redaguok egzistuojantį", + "add_door_textui": "**Naujos durys** \nSąveikauti [LMB] \nAtšaukti [RMB]", + "command_closest": "Atidaryti artimiausių durų UI sąsają" +} diff --git a/resources/[housing]/ox_doorlock/locales/nl.json b/resources/[housing]/ox_doorlock/locales/nl.json new file mode 100644 index 000000000..0447adb12 --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/nl.json @@ -0,0 +1,16 @@ +{ + "unlocked_door": "Open deur", + "locked_door": "Gesloten deur", + "lock_door": "[E] Sluiten", + "unlock_door": "[E] Openen", + "door_lock": "Deurslot", + "passcode": "Toegangscode", + "lockpick_broke": "Je lockpick is gebroken", + "pick_lock": "Pick lock", + "add_lock": "Deurslot toevoegen", + "edit_lock": "Deurslot aanpassen", + "remove_lock": "Deurslot verwijderen", + "cannot_unlock": "Niet mogelijk om de deur te openen", + "cannot_lock": "Niet mogelijk om de deur te sluiten", + "create_modify_lock": "Maak een slot of pas er een aan" +} diff --git a/resources/[housing]/ox_doorlock/locales/no.json b/resources/[housing]/ox_doorlock/locales/no.json new file mode 100644 index 000000000..7592bdfb4 --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/no.json @@ -0,0 +1,18 @@ +{ + "unlocked_door": "Låst opp dør", + "locked_door": "Låst dør", + "lock_door": "[E] Lås dør", + "unlock_door": "[E] Lås opp dør", + "door_lock": "Dørlås", + "passcode": "Passord", + "lockpick_broke": "Din låsdirk har gått i stykker", + "pick_lock": "Dirk låsen", + "add_lock": "Legg til dørlås", + "edit_lock": "Rediger dørlås", + "remove_lock": "Fjern dørlås", + "cannot_unlock": "Kan ikke låse opp døren", + "cannot_lock": "Kan ikke låse døren", + "create_modify_lock": "Opprett en dørlås, eller endre en eksisterende", + "add_door_textui": "Opprett ny dør \nInterager med [LMB] \nAvbryt med [RMB]", + "command_closest": "Åpne UI direkte til nærmeste dørlås" +} \ No newline at end of file diff --git a/resources/[housing]/ox_doorlock/locales/pl.json b/resources/[housing]/ox_doorlock/locales/pl.json new file mode 100644 index 000000000..380710bec --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/pl.json @@ -0,0 +1,18 @@ +{ + "unlocked_door": "Otwarte drzwi", + "locked_door": "Zamknięte drzwi", + "lock_door": "[E] Zamknij drzwi", + "unlock_door": "[E] Otwórz drzwi", + "door_lock": "Zamek", + "passcode": "Hasło", + "lockpick_broke": "Twój wytrych się złamał", + "pick_lock": "Wyłam zamek", + "add_lock": "Dodaj zamek", + "edit_lock": "Edytuj zamek", + "remove_lock": "Usuń zamek", + "cannot_unlock": "Nie możesz otworzyć drzwi", + "cannot_lock": "Nie możesz zamknąć drzwi", + "create_modify_lock": "Utwórz zamek lub edytuj istniejący", + "add_door_textui": "**Utwórz nowy zamek** \nInterakcja z [LMB] \nAnuluj z [RMB]", + "command_closest": "Otwórz UI bezpośrednio do najbliższyego zamka" +} diff --git a/resources/[housing]/ox_doorlock/locales/pt-br.json b/resources/[housing]/ox_doorlock/locales/pt-br.json new file mode 100644 index 000000000..bca8ad2ac --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/pt-br.json @@ -0,0 +1,18 @@ +{ + "unlocked_door": "Porta Destrancada", + "locked_door": "Porta Trancada", + "lock_door": "[E] Trancar Porta", + "unlock_door": "[E] Destrancar Porta", + "door_lock": "Fechadura", + "passcode": "Senha", + "lockpick_broke": "Sua lockpick quebrou", + "pick_lock": "Usar Lockpick", + "add_lock": "Adicionar Fechadura", + "edit_lock": "Editar Fechadura", + "remove_lock": "Remover Fechadura", + "cannot_unlock": "Não foi possivel destrancar a porta", + "cannot_lock": "Não foi possível trancar a porta", + "create_modify_lock": "Criar uma fechadura, ou modificar uma existente", + "add_door_textui": "**Criar nova fechadura** \nInteragir com [LMB] \nCancelar com [RMB]", + "command_closest": "Abra a interface mais próximo da fechadura" +} diff --git a/resources/[housing]/ox_doorlock/locales/pt.json b/resources/[housing]/ox_doorlock/locales/pt.json new file mode 100644 index 000000000..67cad1559 --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/pt.json @@ -0,0 +1,18 @@ +{ + "unlocked_door": "Porta Destrancada", + "locked_door": "Porta Trancada", + "lock_door": "[E] Trancar Porta", + "unlock_door": "[E] Destrancar Porta", + "door_lock": "Fechadura", + "passcode": "Código de Acesso", + "lockpick_broke": "A tua gazua partiu-se", + "pick_lock": "Usar Gazua", + "add_lock": "Adicionar Fechadura", + "edit_lock": "Editar Fechadura", + "remove_lock": "Remover Fechadura", + "cannot_unlock": "Não foi possível destrancar a porta", + "cannot_lock": "Não foi possível trancar a porta", + "create_modify_lock": "Criar uma fechadura ou modificar uma existente", + "add_door_textui": "**Criar nova fechadura** \nInteragir com [LMB] \nCancelar com [RMB]", + "command_closest": "Abra a interface da fechadura mais próxima" +} diff --git a/resources/[housing]/ox_doorlock/locales/sv.json b/resources/[housing]/ox_doorlock/locales/sv.json new file mode 100644 index 000000000..4ab32aa41 --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/sv.json @@ -0,0 +1,16 @@ +{ + "unlocked_door": "Olåst", + "locked_door": "Låst", + "lock_door": "[E] Lås", + "unlock_door": "[E] Lås upp", + "door_lock": "Dörrlås", + "passcode": "Lösenord", + "lockpick_broke": "Ditt dyrkset gick sönder", + "pick_lock": "Dyrka upp dörr", + "add_lock": "Lägg till lås", + "edit_lock": "Redigera lås", + "remove_lock": "Ta bort dörrlås", + "cannot_unlock": "Kan inte låsa upp", + "cannot_lock": "Kan inte låsa", + "create_modify_lock": "Lägg till dörrlås eller redigera befintligt" +} diff --git a/resources/[housing]/ox_doorlock/locales/zh-cn.json b/resources/[housing]/ox_doorlock/locales/zh-cn.json new file mode 100644 index 000000000..835e15deb --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/zh-cn.json @@ -0,0 +1,17 @@ +{ + "unlocked_door": "已将门解锁", + "locked_door": "已将门锁上", + "lock_door": "[E] 锁门", + "unlock_door": "[E] 解锁门", + "door_lock": "门锁", + "passcode": "密码", + "lockpick_broke": "你的开锁工具坏了", + "pick_lock": "撬锁", + "add_lock": "加入门锁", + "edit_lock": "编辑门锁", + "remove_lock": "删除门锁", + "cannot_unlock": "无法解锁门", + "cannot_lock": "无法锁门", + "add_door_textui": "**创建门锁** \n互动 [LMB] \n取消 [RMB]", + "create_modify_lock": "建立或修改已存在的门锁" +} diff --git a/resources/[housing]/ox_doorlock/locales/zh-tw.json b/resources/[housing]/ox_doorlock/locales/zh-tw.json new file mode 100644 index 000000000..de7e85ae9 --- /dev/null +++ b/resources/[housing]/ox_doorlock/locales/zh-tw.json @@ -0,0 +1,17 @@ +{ + "unlocked_door": "已將門解鎖", + "locked_door": "已將門鎖上", + "lock_door": "[E] 鎖門", + "unlock_door": "[E] 解鎖門", + "door_lock": "門鎖", + "passcode": "密碼", + "lockpick_broke": "你的開鎖工具壞了", + "pick_lock": "撬鎖", + "add_lock": "加入門鎖", + "edit_lock": "編輯門鎖", + "remove_lock": "刪除門鎖", + "cannot_unlock": "無法解鎖門", + "cannot_lock": "無法鎖門", + "add_door_textui": "**創建門鎖** \n互動 [LMB] \n取消 [RMB]", + "create_modify_lock": "建立或修改已存在的門鎖" +} diff --git a/resources/[housing]/ox_doorlock/server/convert.lua b/resources/[housing]/ox_doorlock/server/convert.lua new file mode 100644 index 000000000..2d5799ee9 --- /dev/null +++ b/resources/[housing]/ox_doorlock/server/convert.lua @@ -0,0 +1,136 @@ +---@diagnostic disable: inject-field +---@type table? +Config.DoorList = {} + +local utils = require 'server.utils' + +local function flattenTableToArray(tbl) + if type(tbl) == 'table' then + if table.type(tbl) == 'array' then return tbl end + + local array = {} + + for k in pairs(tbl) do + array[#array + 1] = k + end + + return array + end +end + +MySQL.ready(function() + local files, fileCount = utils.getFilesInDirectory('convert', '%.lua') + + if fileCount > 0 then + print(('^3Found %d nui_doorlock config files.^0'):format(fileCount)) + end + + local query = + 'INSERT INTO `ox_doorlock` (`name`, `data`) SELECT ?, ? WHERE NOT EXISTS (SELECT 1 FROM `ox_doorlock` WHERE `name` = ?)' + local queries = {} + + for i = 1, fileCount do + local fileName = files[i] + local file = LoadResourceFile('ox_doorlock', ('convert/%s.lua'):format(fileName)) + + if file then + load(file)() + + if next(Config.DoorList) then + local size = 0 + + for k, door in pairs(Config.DoorList) do + size += 1 + local double = door.doors + local qb = door.objName or (double and double[1].objName) + + if qb then + if double then + for j = 1, 2 do + double[j].objHash = double[j].objName + double[j].objHeading = double[j].objYaw or 0 + end + else + door.objHash = door.objName + door.objHeading = door.objYaw or 0 + end + + local groups = door.authorizedJobs or {} + + if door.authorizedGangs then + for gang, grade in pairs(door.authorizedGangs) do + groups[gang] = grade + end + end + + door.authorizedJobs = next(groups) and groups + door.lockpick = door.pickable + door.showNUI = not door.hideLabel + door.characters = flattenTableToArray(door.authorizedCitizenIDs) + end + + local data = { + auto = door.slides or door.garage or door.sliding or door.doublesliding, + autolock = (door.autolock and door.autolock / 1000) or (door.autoLock and door.autoLock / 1000), + coords = door.objCoords, + heading = door.objHeading and math.floor(door.objHeading + 0.5), + model = door.objHash, + characters = door.characters, + groups = door.authorizedJobs, + items = door.items, + lockpick = door.lockpick, + hideUi = door.showNUI ~= nil and not door.showNUI or false, + lockSound = door.audioLock?.file and door.audioLock.file:gsub('%.ogg', ''), + unlockSound = door.audioUnlock?.file and door.audioUnlock.file:gsub('%.ogg', ''), + maxDistance = door.maxDistance or door.distance, + doorRate = door.doorRate and door.doorRate + 0.0 or nil, + state = door.locked and 1 or 0, + passcode = door.passcode, + doors = double and { + { + coords = double[1].objCoords, + heading = math.floor(double[1].objHeading + 0.5), + model = double[1].objHash, + }, + { + coords = double[2].objCoords, + heading = math.floor(double[2].objHeading + 0.5), + model = double[2].objHash, + }, + }, + } + + if data.auto and not data.lockSound then + if door.audioRemote then + data.lockSound = 'button-remote' + end + end + + if double and not data.coords then + double = data.doors + data.coords = double[1].coords - ((double[1].coords - double[2].coords) / 2) + end + + local name = ('%s %s'):format(fileName, k) + + queries[size] = { + query = query, values = { name, json.encode(data), name } + } + end + + print(('^3Loaded %d doors from convert/%s.lua.^0'):format(size, fileName)) + + if MySQL.transaction.await(queries) then + SaveResourceFile('ox_doorlock', ('convert/%s.lua'):format(fileName), + '-- This file has already been converted for ox_doorlock and should be removed.\r\ndo return end\r\n\r\n' .. + file, -1) + end + + table.wipe(Config.DoorList) + table.wipe(queries) + end + end + end + + Config.DoorList = nil +end) diff --git a/resources/[housing]/ox_doorlock/server/framework/es_extended.lua b/resources/[housing]/ox_doorlock/server/framework/es_extended.lua new file mode 100644 index 000000000..5ee5bf550 --- /dev/null +++ b/resources/[housing]/ox_doorlock/server/framework/es_extended.lua @@ -0,0 +1,65 @@ +local resourceName = 'es_extended' + +SetTimeout(0, function() + local ESX = exports[resourceName]:getSharedObject() + + GetPlayer = ESX.GetPlayerFromId + + if not ESX.GetConfig().OxInventory then + function RemoveItem(playerId, item) + local player = GetPlayer(playerId) + + if player then player.removeInventoryItem(item, 1) end + end + + ---@param player table + ---@param items string[] | { name: string, remove?: boolean, metadata?: string }[] + ---@param removeItem? boolean + ---@return string? + function DoesPlayerHaveItem(player, items, removeItem) + for i = 1, #items do + local item = items[i] + local itemName = item.name or item + local data = player.getInventoryItem(itemName) + + if data?.count > 0 then + if removeItem or item.remove then + player.removeInventoryItem(itemName, 1) + end + + return itemName + end + end + end + end +end) + +function GetCharacterId(player) + return player.identifier +end + +function IsPlayerInGroup(player, filter) + local type = type(filter) + + if type == 'string' then + if player.job.name == filter then + return player.job.name, player.job.grade + end + else + local tabletype = table.type(filter) + + if tabletype == 'hash' then + local grade = filter[player.job.name] + + if grade and grade <= player.job.grade then + return player.job.name, player.job.grade + end + elseif tabletype == 'array' then + for i = 1, #filter do + if player.job.name == filter[i] then + return player.job.name, player.job.grade + end + end + end + end +end diff --git a/resources/[housing]/ox_doorlock/server/framework/nd_core.lua b/resources/[housing]/ox_doorlock/server/framework/nd_core.lua new file mode 100644 index 000000000..249ff3116 --- /dev/null +++ b/resources/[housing]/ox_doorlock/server/framework/nd_core.lua @@ -0,0 +1,36 @@ +local resourceName = 'ND_Core' +local NDCore = exports[resourceName] + +function GetPlayer(src) + return NDCore:getPlayer(src) +end + +function GetCharacterId(player) + return player.id +end + +function IsPlayerInGroup(player, groups) + local type = type(groups) + + if type == "string" then + return player.getGroup(groups) + end + + if table.type(groups) == "array" then + for i = 1, #groups do + local groupName = groups[i] + local groupInfo = player.getGroup(groupName) + if groupInfo then + return groupName, groupInfo.rank + end + end + return + end + + for groupName, grade in pairs(groups) do + local groupInfo = player.getGroup(groupName) + if groupInfo and grade and grade <= groupInfo.rank then + return groupName, groupInfo.rank + end + end +end diff --git a/resources/[housing]/ox_doorlock/server/framework/ox_core.lua b/resources/[housing]/ox_doorlock/server/framework/ox_core.lua new file mode 100644 index 000000000..64521d14e --- /dev/null +++ b/resources/[housing]/ox_doorlock/server/framework/ox_core.lua @@ -0,0 +1,16 @@ +if not lib.checkDependency('ox_core', '0.21.3', true) then return end + +local Ox = require '@ox_core.lib.init' --[[@as OxServer]] + +GetPlayer = Ox.GetPlayer + +---@param player OxPlayerServer +function GetCharacterId(player) + return player.charId +end + +---@param player OxPlayerServer +---@param groups string | string[] | table +function IsPlayerInGroup(player, groups) + return player.getGroup(groups) +end diff --git a/resources/[housing]/ox_doorlock/server/framework/qb-core.lua b/resources/[housing]/ox_doorlock/server/framework/qb-core.lua new file mode 100644 index 000000000..322420d73 --- /dev/null +++ b/resources/[housing]/ox_doorlock/server/framework/qb-core.lua @@ -0,0 +1,97 @@ +local resourceName = 'qb-core' + +SetTimeout(0, function() + local QB = exports[resourceName]:GetCoreObject() + + GetPlayer = QB.Functions.GetPlayer + + if GetResourceState('ox_inventory') == 'missing' then + function RemoveItem(playerId, item, slot) + local player = GetPlayer(playerId) + + if player then player.Functions.RemoveItem(item, 1, slot) end + end + + ---@param player table + ---@param items string[] | { name: string, remove?: boolean, metadata?: string }[] + ---@param removeItem? boolean + ---@return string? + function DoesPlayerHaveItem(player, items, removeItem) + for i = 1, #items do + local item = items[i] + local itemName = item.name or item + + if item.metadata then + local playerItems = player.Functions.GetItemsByName(itemName) + + for j = 1, #playerItems do + local data = playerItems[j] + + if data.info.type == item.metadata then + if removeItem or item.remove then + player.Functions.RemoveItem(itemName, 1, data.slot) + end + + return itemName + end + end + else + local data = player.Functions.GetItemByName(itemName) + + if data then + if item.remove then + player.Functions.RemoveItem(itemName, 1, data.slot) + end + + return itemName + end + end + end + end + end +end) + +function GetCharacterId(player) + return player.PlayerData.citizenid +end + +local groups = { 'job', 'gang' } + +function IsPlayerInGroup(player, filter) + local type = type(filter) + + if type == 'string' then + for i = 1, #groups do + local data = player.PlayerData[groups[i]] + + if data.name == filter then + return data.name, data.grade.level + end + end + else + local tabletype = table.type(filter) + + if tabletype == 'hash' then + for i = 1, #groups do + local data = player.PlayerData[groups[i]] + local grade = filter[data.name] + + if grade and grade <= data.grade.level then + return data.name, data.grade.level + end + end + elseif tabletype == 'array' then + for i = 1, #filter do + local group = filter[i] + + for j = 1, #groups do + local data = player.PlayerData[groups[j]] + + if data.name == group then + return data.name, data.grade.level + end + end + end + end + end +end diff --git a/resources/[housing]/ox_doorlock/server/main.lua b/resources/[housing]/ox_doorlock/server/main.lua new file mode 100644 index 000000000..d653eeec5 --- /dev/null +++ b/resources/[housing]/ox_doorlock/server/main.lua @@ -0,0 +1,377 @@ +if not LoadResourceFile(cache.resource, 'web/build/index.html') then + error( + 'Unable to load UI. Build ox_doorlock or download the latest release.\n ^3https://github.com/overextended/ox_doorlock/releases/latest/download/ox_doorlock.zip^0') +end + +if not lib.checkDependency('oxmysql', '2.4.0') then return end +if not lib.checkDependency('ox_lib', '3.14.0') then return end + +lib.versionCheck('overextended/ox_doorlock') +require 'server.convert' + +local utils = require 'server.utils' +local doors = {} + + +local function encodeData(door) + local double = door.doors + + return json.encode({ + auto = door.auto, + autolock = door.autolock, + coords = door.coords, + doors = double and { + { + coords = double[1].coords, + heading = double[1].heading, + model = double[1].model, + }, + { + coords = double[2].coords, + heading = double[2].heading, + model = double[2].model, + }, + }, + characters = door.characters, + groups = door.groups, + heading = door.heading, + items = door.items, + lockpick = door.lockpick, + hideUi = door.hideUi, + holdOpen = door.holdOpen, + lockSound = door.lockSound, + maxDistance = door.maxDistance, + doorRate = door.doorRate, + model = door.model, + state = door.state, + unlockSound = door.unlockSound, + passcode = door.passcode, + lockpickDifficulty = door.lockpickDifficulty + }) +end + +local function getDoor(door) + door = type(door) == 'table' and door or doors[door] + if not door then return false end + return { + id = door.id, + name = door.name, + state = door.state, + coords = door.coords, + characters = door.characters, + groups = door.groups, + items = door.items, + maxDistance = door.maxDistance, + } +end + +exports('getDoor', getDoor) + +exports('getAllDoors', function() + local allDoors = {} + + for _, door in pairs(doors) do + allDoors[#allDoors+1] = getDoor(door) + end + + return allDoors +end) + +exports('getDoorFromName', function(name) + for _, door in pairs(doors) do + if door.name == name then + return getDoor(door) + end + end +end) + +exports('editDoor', function(id, data) + local door = doors[id] + + if door then + for k, v in pairs(data) do + if k ~= 'id' then + local current = door[k] + local t1 = type(current) + local t2 = type(v) + + if t1 ~= 'nil' and v ~= '' and t1 ~= t2 then + error(("Expected '%s' for door.%s, received %s (%s)"):format(t1, k, t2, v)) + end + + door[k] = v ~= '' and v or nil + end + end + + MySQL.update('UPDATE ox_doorlock SET name = ?, data = ? WHERE id = ?', { door.name, encodeData(door), id }) + TriggerClientEvent('ox_doorlock:editDoorlock', -1, id, door) + end +end) + +local soundDirectory = Config.NativeAudio and 'audio/dlc_oxdoorlock/oxdoorlock' or 'web/build/sounds' +local fileFormat = Config.NativeAudio and '%.wav' or '%.ogg' +local sounds = utils.getFilesInDirectory(soundDirectory, fileFormat) + +lib.callback.register('ox_doorlock:getSounds', function() + return sounds +end) + +local function createDoor(id, door, name) + local double = door.doors + door.id = id + door.name = name + + if double then + for i = 1, 2 do + double[i].hash = joaat(('ox_door_%s_%s'):format(id, i)) + + local coords = double[i].coords + double[i].coords = vector3(coords.x, coords.y, coords.z) + end + + if not door.coords then + door.coords = double[1].coords - ((double[1].coords - double[2].coords) / 2) + end + else + door.hash = joaat(('ox_door_%s'):format(id)) + end + + door.coords = vector3(door.coords.x, door.coords.y, door.coords.z) + + if not door.state then + door.state = 1 + end + + if type(door.items?[1]) == 'string' then + local items = {} + + for i = 1, #door.items do + items[i] = { + name = door.items[i], + remove = false, + } + end + + door.items = items + MySQL.update('UPDATE ox_doorlock SET data = ? WHERE id = ?', { encodeData(door), id }) + end + + doors[id] = door + return door +end + +local isLoaded = false +local ox_inventory = exports.ox_inventory + +SetTimeout(0, function() + if GetPlayer then return end + + function GetPlayer(_) end +end) + +function RemoveItem(playerId, item, slot) + local player = GetPlayer(playerId) + + if player then ox_inventory:RemoveItem(playerId, item, 1, nil, slot) end +end + +---@param player table +---@param items string[] | { name: string, remove?: boolean, metadata?: string }[] +---@param removeItem? boolean +---@return string? +function DoesPlayerHaveItem(player, items, removeItem) + local playerId = player.source or player.PlayerData.source + + for i = 1, #items do + local item = items[i] + local itemName = item.name or item + local data = ox_inventory:Search(playerId, 'slots', itemName, item.metadata)[1] + + if data and data.count > 0 then + if removeItem or item.remove then + ox_inventory:RemoveItem(playerId, itemName, 1, nil, data.slot) + end + + return itemName + end + end +end + +local function isAuthorised(playerId, door, lockpick) + if Config.PlayerAceAuthorised and IsPlayerAceAllowed(playerId, 'command.doorlock') then + return true + end + + -- e.g. add_ace group.police "doorlock.mrpd locker rooms" allow + -- add_principal fivem:123456 group.police + -- or add_ace identifier.fivem:123456 "doorlock.mrpd locker rooms" allow + if IsPlayerAceAllowed(playerId, ('doorlock.%s'):format(door.name)) then + return true + end + + local player = GetPlayer(playerId) + local authorised = door.passcode or false --[[@as boolean | string | nil]] + + if player then + if lockpick then + return DoesPlayerHaveItem(player, Config.LockpickItems) + end + + if door.characters and table.contains(door.characters, GetCharacterId(player)) then + return true + end + + if door.groups then + authorised = IsPlayerInGroup(player, door.groups) and true or nil + end + + if not authorised and door.items then + authorised = DoesPlayerHaveItem(player, door.items) or nil + end + + if authorised ~= nil and door.passcode then + authorised = door.passcode == lib.callback.await('ox_doorlock:inputPassCode', playerId) + end + + ------------------------------------ + ------- Brutal Housing Editing ----- + ------------------------------------ + + if GetResourceState("brutal_housing") == "started" then + local propertyID = door.name:match("^(.-)_") + if propertyID ~= nil then + TriggerEvent('brutal_housing:server:hasKeyToHouse', playerId, propertyID, function(hasKey) + authorised = hasKey + end) + end + end + + ------------------------------------ + ------- Brutal Housing Editing ----- + ------------------------------------ + end + + return authorised +end + +local sql = LoadResourceFile(cache.resource, 'sql/ox_doorlock.sql') + +if sql then MySQL.query(sql) end + +MySQL.ready(function() + while Config.DoorList do Wait(100) end + + local response = MySQL.query.await('SELECT `id`, `name`, `data` FROM `ox_doorlock`') + + for i = 1, #response do + local door = response[i] + createDoor(door.id, json.decode(door.data), door.name) + end + + isLoaded = true + + TriggerEvent('ox_doorlock:loaded') +end) + +---@param id number +---@param state 0 | 1 | boolean +---@param lockpick? boolean +---@return boolean +local function setDoorState(id, state, lockpick) + local door = doors[id] + + state = (state == 1 or state == 0) and state or (state and 1 or 0) + + if door then + local authorised = not source or source == '' or isAuthorised(source, door, lockpick) + + if authorised then + door.state = state + TriggerClientEvent('ox_doorlock:setState', -1, id, state, source) + + if door.autolock and state == 0 then + SetTimeout(door.autolock * 1000, function() + if door.state ~= 1 then + door.state = 1 + + TriggerClientEvent('ox_doorlock:setState', -1, id, door.state) + TriggerEvent('ox_doorlock:stateChanged', nil, door.id, door.state == 1) + end + end) + end + + TriggerEvent('ox_doorlock:stateChanged', source, door.id, state == 1, + type(authorised) == 'string' and authorised) + + return true + end + + if source then + lib.notify(source, + { type = 'error', icon = 'lock', description = state == 0 and 'cannot_unlock' or 'cannot_lock' }) + end + end + + return false +end + +RegisterNetEvent('ox_doorlock:setState', setDoorState) +exports('setDoorState', setDoorState) + +lib.callback.register('ox_doorlock:getDoors', function() + while not isLoaded do Wait(100) end + + return doors, sounds +end) + +RegisterNetEvent('ox_doorlock:editDoorlock', function(id, data) + if IsPlayerAceAllowed(source, 'command.doorlock') then + if data then + if not data.coords then + local double = data.doors + data.coords = double[1].coords - ((double[1].coords - double[2].coords) / 2) + end + + if not data.name then + data.name = tostring(data.coords) + end + end + + if id then + if data then + MySQL.update('UPDATE ox_doorlock SET name = ?, data = ? WHERE id = ?', + { data.name, encodeData(data), id }) + else + MySQL.update('DELETE FROM ox_doorlock WHERE id = ?', { id }) + end + + doors[id] = data + TriggerClientEvent('ox_doorlock:editDoorlock', -1, id, data) + else + local insertId = MySQL.insert.await('INSERT INTO ox_doorlock (name, data) VALUES (?, ?)', + { data.name, encodeData(data) }) + local door = createDoor(insertId, data, data.name) + + TriggerClientEvent('ox_doorlock:setState', -1, door.id, door.state, false, door) + end + end +end) + +RegisterNetEvent('ox_doorlock:breakLockpick', function() + local player = GetPlayer(source) + return player and DoesPlayerHaveItem(player, Config.LockpickItems, true) +end) + +lib.addCommand('doorlock', { + help = locale('create_modify_lock'), + params = { + { + name = 'closest', + help = locale('command_closest'), + optional = true, + }, + }, + restricted = Config.CommandPrincipal +}, function(source, args) + TriggerClientEvent('ox_doorlock:triggeredCommand', source, args.closest) +end) diff --git a/resources/[housing]/ox_doorlock/server/utils.lua b/resources/[housing]/ox_doorlock/server/utils.lua new file mode 100644 index 000000000..9c89ce20d --- /dev/null +++ b/resources/[housing]/ox_doorlock/server/utils.lua @@ -0,0 +1,44 @@ +local resourcePath = GetResourcePath(cache.resource):gsub('//', '/') .. '/' + +local utils = {} + +function utils.getFilesInDirectory(path, pattern) + local files = {} + local fileCount = 0 + local system = os.getenv('OS') + local command = system and system:match('Windows') and 'dir "' or 'ls "' + local suffix = command == 'dir "' and '/" /b' or '/"' + local dir = io.popen(command .. resourcePath .. path .. suffix) + + if dir then + for line in dir:lines() do + if line:match(pattern) then + fileCount += 1 + files[fileCount] = line:gsub(pattern, '') + end + end + + dir:close() + end + + return files, fileCount +end + +local frameworks = { 'es_extended', 'ND_Core', 'ox_core', 'qb-core' } +local sucess = false + +for i = 1, #frameworks do + local framework = frameworks[i] + + if GetResourceState(framework):find('start') then + require(('server.framework.%s'):format(framework:lower())) + sucess = true + break + end +end + +if not sucess then + warn('no compatible framework was loaded, most features will not work') +end + +return utils diff --git a/resources/[housing]/ox_doorlock/sql/community_mrpd.sql b/resources/[housing]/ox_doorlock/sql/community_mrpd.sql new file mode 100644 index 000000000..703c48f67 --- /dev/null +++ b/resources/[housing]/ox_doorlock/sql/community_mrpd.sql @@ -0,0 +1,37 @@ +/* + Run this file after ox_doorlock.sql + Works with https://www.gta5-mods.com/maps/community-mission-row-pd +*/ + +INSERT INTO `ox_doorlock` (`id`, `name`, `data`) VALUES + (1, 'community_mrpd 1', '{"coords":{"x":434.7478942871094,"y":-981.916748046875,"z":30.83926963806152},"groups":{"police":0,"offpolice":0},"maxDistance":2.5,"state":0,"doors":[{"coords":{"x":434.7478942871094,"y":-980.618408203125,"z":30.83926963806152},"model":-1215222675,"heading":270},{"coords":{"x":434.7478942871094,"y":-983.215087890625,"z":30.83926963806152},"model":320433149,"heading":270}],"hideUi":false}'), + (2, 'community_mrpd 2', '{"coords":{"x":468.6697998046875,"y":-1014.4520263671875,"z":26.53623962402343},"groups":{"police":0},"maxDistance":2.5,"state":1,"doors":[{"coords":{"x":469.9679870605469,"y":-1014.4520263671875,"z":26.53623962402343},"model":-2023754432,"heading":180},{"coords":{"x":467.3716125488281,"y":-1014.4520263671875,"z":26.53623962402343},"model":-2023754432,"heading":0}],"hideUi":false}'), + (3, 'community_mrpd 3', '{"coords":{"x":463.4783020019531,"y":-1003.5380249023438,"z":25.00598907470703},"model":-1033001619,"groups":{"police":0},"heading":0,"maxDistance":2,"state":1,"hideUi":false}'), + (4, 'community_mrpd 4', '{"coords":{"x":488.8948059082031,"y":-1017.2100219726563,"z":27.14863014221191},"auto":true,"lockSound":"button-remote","groups":{"police":0},"heading":90,"maxDistance":5,"state":1,"model":-1603817716,"hideUi":false}'), + (5, 'community_mrpd 5', '{"coords":{"x":431.4056091308594,"y":-1001.1690063476563,"z":26.71261024475097},"auto":true,"lockSound":"button-remote","groups":{"police":0},"heading":0,"maxDistance":5,"state":1,"model":-190780785,"hideUi":false}'), + (6, 'community_mrpd 6', '{"coords":{"x":436.223388671875,"y":-1001.1690063476563,"z":26.71261024475097},"auto":true,"lockSound":"button-remote","groups":{"police":0},"heading":0,"maxDistance":5,"state":1,"model":-190780785,"hideUi":false}'), + (7, 'community_mrpd 7', '{"coords":{"x":450.10418701171877,"y":-985.7384033203125,"z":30.83930969238281},"model":1557126584,"groups":{"police":0,"offpolice":0},"heading":90,"maxDistance":2,"state":1,"hideUi":false}'), + (8, 'community_mrpd 8', '{"coords":{"x":464.15838623046877,"y":-1011.260009765625,"z":33.01121139526367},"model":507213820,"groups":{"police":0},"heading":0,"maxDistance":2,"state":1,"hideUi":false}'), + (9, 'community_mrpd 9', '{"coords":{"x":461.2864990234375,"y":-985.3206176757813,"z":30.83926963806152},"model":749848321,"groups":{"police":0},"heading":90,"maxDistance":2,"state":1,"hideUi":false}'), + (10, 'community_mrpd 10', '{"coords":{"x":446.57281494140627,"y":-980.0106201171875,"z":30.83930969238281},"model":-1320876379,"groups":{"police":0},"heading":180,"maxDistance":2,"state":1,"hideUi":false}'), + (11, 'community_mrpd 11', '{"coords":{"x":453.09381103515627,"y":-983.2293701171875,"z":30.83926963806152},"model":-1033001619,"groups":{"police":0},"heading":91,"maxDistance":2,"state":1,"hideUi":false}'), + (12, 'community_mrpd 12', '{"coords":{"x":464.36138916015627,"y":-984.677978515625,"z":43.83443832397461},"model":-340230128,"groups":{"police":0},"heading":90,"maxDistance":2,"state":1,"hideUi":false}'), + (13, 'community_mrpd 13', '{"coords":{"x":442.6625061035156,"y":-988.2412719726563,"z":26.81977081298828},"model":-131296141,"groups":{"police":0},"heading":179,"maxDistance":2,"state":1,"hideUi":false}'), + (14, 'community_mrpd 14', '{"coords":{"x":471.3153991699219,"y":-986.1090698242188,"z":25.05794906616211},"model":-131296141,"groups":{"police":0},"heading":270,"maxDistance":2,"state":1,"hideUi":false}'), + (15, 'community_mrpd 15', '{"coords":{"x":467.5935974121094,"y":-977.9932861328125,"z":25.05794906616211},"model":-131296141,"groups":{"police":0},"heading":180,"maxDistance":2,"state":1,"hideUi":false}'), + (16, 'community_mrpd 16', '{"coords":{"x":463.6145935058594,"y":-980.5814208984375,"z":25.05794906616211},"model":-131296141,"groups":{"police":0},"heading":90,"maxDistance":2,"state":1,"hideUi":false}'), + (17, 'community_mrpd 17', '{"coords":{"x":464.5701904296875,"y":-992.6641235351563,"z":25.0644302368164},"model":631614199,"lockSound":"metal-locker","groups":{"police":0},"heading":0,"maxDistance":2,"state":1,"unlockSound":"metallic-creak","hideUi":false}'), + (18, 'community_mrpd 18', '{"coords":{"x":461.8064880371094,"y":-994.4086303710938,"z":25.0644302368164},"model":631614199,"lockSound":"metal-locker","groups":{"police":0},"heading":270,"maxDistance":2,"state":1,"unlockSound":"metallic-creak","hideUi":false}'), + (19, 'community_mrpd 19', '{"coords":{"x":461.8064880371094,"y":-997.6583862304688,"z":25.0644302368164},"model":631614199,"lockSound":"metal-locker","groups":{"police":0},"heading":90,"maxDistance":2,"state":1,"unlockSound":"metallic-creak","hideUi":false}'), + (20, 'community_mrpd 20', '{"coords":{"x":461.8064880371094,"y":-1001.302001953125,"z":25.0644302368164},"model":631614199,"lockSound":"metal-locker","groups":{"police":0},"heading":90,"maxDistance":2,"state":1,"unlockSound":"metallic-creak","hideUi":false}'), + (21, 'community_mrpd 21', '{"coords":{"x":467.19219970703127,"y":-996.4594116210938,"z":25.00598907470703},"model":-1033001619,"groups":{"police":0},"heading":0,"maxDistance":2,"state":1,"hideUi":false}'), + (22, 'community_mrpd 22', '{"coords":{"x":471.4754943847656,"y":-996.4594116210938,"z":25.00598907470703},"model":-1033001619,"groups":{"police":0},"heading":0,"maxDistance":2,"state":1,"hideUi":false}'), + (23, 'community_mrpd 23', '{"coords":{"x":475.7543029785156,"y":-996.4594116210938,"z":25.00598907470703},"model":-1033001619,"groups":{"police":0},"heading":0,"maxDistance":2,"state":1,"hideUi":false}'), + (24, 'community_mrpd 24', '{"coords":{"x":480.03009033203127,"y":-996.4594116210938,"z":25.00598907470703},"model":-1033001619,"groups":{"police":0},"heading":0,"maxDistance":2,"state":1,"hideUi":false}'), + (25, 'community_mrpd 25', '{"coords":{"x":468.4872131347656,"y":-1003.5479736328125,"z":25.01313972473144},"model":-1033001619,"groups":{"police":0},"heading":180,"maxDistance":2,"state":1,"hideUi":false}'), + (26, 'community_mrpd 26', '{"coords":{"x":471.4747009277344,"y":-1003.5380249023438,"z":25.01222991943359},"model":-1033001619,"groups":{"police":0},"heading":0,"maxDistance":2,"state":1,"hideUi":false}'), + (27, 'community_mrpd 27', '{"coords":{"x":477.0495910644531,"y":-1003.552001953125,"z":25.01203918457031},"auto":false,"groups":{"police":0},"heading":179,"lockpick":false,"maxDistance":2,"state":1,"model":-1033001619,"hideUi":false}'), + (28, 'community_mrpd 28', '{"coords":{"x":480.03009033203127,"y":-1003.5380249023438,"z":25.00598907470703},"model":-1033001619,"groups":{"police":0},"heading":0,"maxDistance":2,"state":1,"hideUi":false}'), + (29, 'community_mrpd 29', '{"coords":{"x":444.7078857421875,"y":-989.4453735351563,"z":30.83930969238281},"groups":{"police":0},"maxDistance":2.5,"state":1,"doors":[{"coords":{"x":443.4078063964844,"y":-989.4453735351563,"z":30.83930969238281},"model":185711165,"heading":180},{"coords":{"x":446.00799560546877,"y":-989.4453735351563,"z":30.83930969238281},"model":185711165,"heading":0}],"hideUi":false}'), + (30, 'community_mrpd 30', '{"coords":{"x":445.9197998046875,"y":-999.0016479492188,"z":30.7890396118164},"groups":{"police":0},"maxDistance":2.5,"state":1,"doors":[{"coords":{"x":447.2184143066406,"y":-999.0023193359375,"z":30.78941917419433},"model":-1033001619,"heading":180},{"coords":{"x":444.6211853027344,"y":-999.0009765625,"z":30.78866004943847},"model":-1033001619,"heading":0}],"hideUi":false}'), + (31, 'community_mrpd 31', '{"coords":{"x":445.9298400878906,"y":-997.044677734375,"z":30.84351921081543},"groups":{"police":0},"maxDistance":2.5,"state":0,"doors":[{"coords":{"x":444.62939453125,"y":-997.044677734375,"z":30.84351921081543},"model":-2023754432,"heading":0},{"coords":{"x":447.23028564453127,"y":-997.044677734375,"z":30.84351921081543},"model":-2023754432,"heading":180}],"hideUi":false}'); diff --git a/resources/[housing]/ox_doorlock/sql/default.sql b/resources/[housing]/ox_doorlock/sql/default.sql new file mode 100644 index 000000000..e2d05aa71 --- /dev/null +++ b/resources/[housing]/ox_doorlock/sql/default.sql @@ -0,0 +1,17 @@ +/* + Run this file after ox_doorlock.sql + Works with the standard Mission Row PD interior +*/ + +INSERT INTO `ox_doorlock` (`id`, `name`, `data`) VALUES + (1, 'mrpd locker rooms', '{"maxDistance":2,"heading":90,"coords":{"x":450.1041259765625,"y":-985.7384033203125,"z":30.83930206298828},"groups":{"police":0},"state":1,"model":1557126584,"hideUi":false}'), + (2, 'mrpd cells/briefing', '{"maxDistance":2,"coords":{"x":444.7078552246094,"y":-989.4454345703125,"z":30.83930206298828},"doors":[{"model":185711165,"coords":{"x":446.0079345703125,"y":-989.4454345703125,"z":30.83930206298828},"heading":0},{"model":185711165,"coords":{"x":443.40777587890627,"y":-989.4454345703125,"z":30.83930206298828},"heading":180}],"groups":{"police":0},"state":1,"hideUi":false}'), + (3, 'mrpd cell 3', '{"maxDistance":2,"heading":90,"coords":{"x":461.8065185546875,"y":-1001.9515380859375,"z":25.06442832946777},"lockSound":"metal-locker","groups":{"police":0},"state":1,"unlockSound":"metallic-creak","model":631614199,"hideUi":false}'), + (4, 'mrpd back entrance', '{"maxDistance":2,"coords":{"x":468.6697692871094,"y":-1014.4520263671875,"z":26.5362319946289},"doors":[{"model":-2023754432,"coords":{"x":467.37164306640627,"y":-1014.4520263671875,"z":26.5362319946289},"heading":0},{"model":-2023754432,"coords":{"x":469.9678955078125,"y":-1014.4520263671875,"z":26.5362319946289},"heading":180}],"groups":{"police":0},"state":1,"hideUi":false}'), + (5, 'mrpd cells security door', '{"maxDistance":2,"heading":0,"coords":{"x":464.1282958984375,"y":-1003.5386962890625,"z":25.00598907470703},"autolock":5,"groups":{"police":0},"state":1,"model":-1033001619,"hideUi":false}'), + (6, 'mrpd cell 2', '{"maxDistance":2,"heading":90,"coords":{"x":461.8064880371094,"y":-998.3082885742188,"z":25.06442832946777},"lockSound":"metal-locker","groups":{"police":0},"state":1,"unlockSound":"metallic-creak","model":631614199,"hideUi":false}'), + (7, 'mrpd captain\'s office', '{"maxDistance":2,"heading":180,"coords":{"x":446.57281494140627,"y":-980.0105590820313,"z":30.83930206298828},"groups":{"police":0},"state":1,"model":-1320876379,"hideUi":false}'), + (8, 'mrpd gate', '{"maxDistance":6,"heading":90,"coords":{"x":488.894775390625,"y":-1017.2102661132813,"z":27.14714050292968},"groups":{"police":0},"auto":true,"state":1,"model":-1603817716,"hideUi":false}'), + (9, 'mrpd cell 1', '{"maxDistance":2,"heading":270,"coords":{"x":461.8065185546875,"y":-993.7586059570313,"z":25.06442832946777},"lockSound":"metal-locker","groups":{"police":0},"state":1,"unlockSound":"metallic-creak","model":631614199,"hideUi":false}'), + (10, 'mrpd cells main', '{"maxDistance":2,"heading":360,"coords":{"x":463.92010498046877,"y":-992.6640625,"z":25.06442832946777},"lockSound":"metal-locker","groups":{"police":0},"state":1,"unlockSound":"metallic-creak","model":631614199,"hideUi":false}'), + (11, 'mrpd armoury', '{"maxDistance":2,"heading":270,"coords":{"x":453.08428955078127,"y":-982.5794677734375,"z":30.81926536560058},"autolock":5,"groups":{"police":0},"state":1,"model":749848321,"hideUi":false}'); diff --git a/resources/[housing]/ox_doorlock/sql/ox_doorlock.sql b/resources/[housing]/ox_doorlock/sql/ox_doorlock.sql new file mode 100644 index 000000000..6114073c1 --- /dev/null +++ b/resources/[housing]/ox_doorlock/sql/ox_doorlock.sql @@ -0,0 +1,7 @@ +CREATE TABLE + IF NOT EXISTS `ox_doorlock` ( + `id` int (11) unsigned NOT NULL AUTO_INCREMENT, + `name` varchar(50) NOT NULL, + `data` longtext NOT NULL, + PRIMARY KEY (`id`) + ); diff --git a/resources/[housing]/ox_doorlock/types.lua b/resources/[housing]/ox_doorlock/types.lua new file mode 100644 index 000000000..38e798879 --- /dev/null +++ b/resources/[housing]/ox_doorlock/types.lua @@ -0,0 +1,23 @@ +---@class DrawSpriteProps +---@field [1] string textureDict +---@field [2] string textureName +---@field [3] number screenX +---@field [4] number screenY +---@field [5] number width +---@field [6] number height +---@field [7] number heading +---@field [8] integer red +---@field [9] integer green +---@field [10] integer blue +---@field [11] integer alpha + +---@class DoorlockConfig +---@field Notify boolean +---@field DrawTextUI boolean +---@field CommandPrincipal string +---@field PlayerAceAuthorised boolean +---@field LockDifficulty SkillCheckDifficulity | SkillCheckDifficulity[] +---@field CanPickUnlockedDoors boolean +---@field LockpickItems string[] +---@field NativeAudio boolean +---@field DrawSprite { [0]: DrawSpriteProps, [1]: DrawSpriteProps } diff --git a/resources/[housing]/ox_doorlock/web/build/assets/index.828bc70f.css b/resources/[housing]/ox_doorlock/web/build/assets/index.828bc70f.css new file mode 100644 index 000000000..b09672650 --- /dev/null +++ b/resources/[housing]/ox_doorlock/web/build/assets/index.828bc70f.css @@ -0,0 +1 @@ +@import"https://fonts.googleapis.com/css2?family=Nunito:wght@200;300;400;500;600;700&display=swap";@import"https://use.typekit.net/qgr5ebd.css";body{margin:0;font-family:Roboto,-apple-system,BlinkMacSystemFont,Segoe UI,Oxygen,Ubuntu,Cantarell,Fira Sans,Droid Sans,Helvetica Neue,sans-serif;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;height:100vh;user-select:none;background:none!important;overflow:hidden}#root{height:100%}code{font-family:source-code-pro,Menlo,Monaco,Consolas,Courier New,monospace}::-webkit-scrollbar{width:3px;border-radius:3px}::-webkit-scrollbar-track{background:rgb(95,95,95);border-radius:3px}::-webkit-scrollbar-thumb{background:#888;border-radius:3px}input::-webkit-outer-spin-button,input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0} diff --git a/resources/[housing]/ox_doorlock/web/build/assets/index.9bf400a2.js b/resources/[housing]/ox_doorlock/web/build/assets/index.9bf400a2.js new file mode 100644 index 000000000..6c3469a94 --- /dev/null +++ b/resources/[housing]/ox_doorlock/web/build/assets/index.9bf400a2.js @@ -0,0 +1,93 @@ +function vx(e,t){return t.forEach(function(r){r&&typeof r!="string"&&!Array.isArray(r)&&Object.keys(r).forEach(function(n){if(n!=="default"&&!(n in e)){var o=Object.getOwnPropertyDescriptor(r,n);Object.defineProperty(e,n,o.get?o:{enumerable:!0,get:function(){return r[n]}})}})}),Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}const hx=function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))n(o);new MutationObserver(o=>{for(const i of o)if(i.type==="childList")for(const l of i.addedNodes)l.tagName==="LINK"&&l.rel==="modulepreload"&&n(l)}).observe(document,{childList:!0,subtree:!0});function r(o){const i={};return o.integrity&&(i.integrity=o.integrity),o.referrerpolicy&&(i.referrerPolicy=o.referrerpolicy),o.crossorigin==="use-credentials"?i.credentials="include":o.crossorigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function n(o){if(o.ep)return;o.ep=!0;const i=r(o);fetch(o.href,i)}};hx();var g={exports:{}},J={};/* +object-assign +(c) Sindre Sorhus +@license MIT +*/var hp=Object.getOwnPropertySymbols,yx=Object.prototype.hasOwnProperty,wx=Object.prototype.propertyIsEnumerable;function _x(e){if(e==null)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}function Sx(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de",Object.getOwnPropertyNames(e)[0]==="5")return!1;for(var t={},r=0;r<10;r++)t["_"+String.fromCharCode(r)]=r;var n=Object.getOwnPropertyNames(t).map(function(i){return t[i]});if(n.join("")!=="0123456789")return!1;var o={};return"abcdefghijklmnopqrst".split("").forEach(function(i){o[i]=i}),Object.keys(Object.assign({},o)).join("")==="abcdefghijklmnopqrst"}catch{return!1}}var P0=Sx()?Object.assign:function(e,t){for(var r,n=_x(e),o,i=1;i"u"||typeof MessageChannel!="function"){var s=null,u=null,c=function(){if(s!==null)try{var R=e.unstable_now();s(!0,R),s=null}catch(T){throw setTimeout(c,0),T}};t=function(R){s!==null?setTimeout(t,0,R):(s=R,setTimeout(c,0))},r=function(R,T){u=setTimeout(R,T)},n=function(){clearTimeout(u)},e.unstable_shouldYield=function(){return!1},o=e.unstable_forceFrameRate=function(){}}else{var f=window.setTimeout,d=window.clearTimeout;if(typeof console<"u"){var p=window.cancelAnimationFrame;typeof window.requestAnimationFrame!="function"&&console.error("This browser doesn't support requestAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills"),typeof p!="function"&&console.error("This browser doesn't support cancelAnimationFrame. Make sure that you load a polyfill in older browsers. https://reactjs.org/link/react-polyfills")}var y=!1,w=null,v=-1,m=5,h=0;e.unstable_shouldYield=function(){return e.unstable_now()>=h},o=function(){},e.unstable_forceFrameRate=function(R){0>R||125>>1,M=R[k];if(M!==void 0&&0<$(M,T))R[k]=T,R[A]=M,A=k;else break e}}function x(R){return R=R[0],R===void 0?null:R}function P(R){var T=R[0];if(T!==void 0){var A=R.pop();if(A!==T){R[0]=A;e:for(var k=0,M=R.length;k$(Z,A))ae!==void 0&&0>$(ae,Z)?(R[k]=ae,R[ze]=A,k=ze):(R[k]=Z,R[G]=A,k=G);else if(ae!==void 0&&0>$(ae,A))R[k]=ae,R[ze]=A,k=ze;else break e}}return T}return null}function $(R,T){var A=R.sortIndex-T.sortIndex;return A!==0?A:R.id-T.id}var C=[],I=[],z=1,D=null,j=3,B=!1,V=!1,W=!1;function re(R){for(var T=x(I);T!==null;){if(T.callback===null)P(I);else if(T.startTime<=R)P(I),T.sortIndex=T.expirationTime,O(C,T);else break;T=x(I)}}function se(R){if(W=!1,re(R),!V)if(x(C)!==null)V=!0,t(ie);else{var T=x(I);T!==null&&r(se,T.startTime-R)}}function ie(R,T){V=!1,W&&(W=!1,n()),B=!0;var A=j;try{for(re(T),D=x(C);D!==null&&(!(D.expirationTime>T)||R&&!e.unstable_shouldYield());){var k=D.callback;if(typeof k=="function"){D.callback=null,j=D.priorityLevel;var M=k(D.expirationTime<=T);T=e.unstable_now(),typeof M=="function"?D.callback=M:D===x(C)&&P(C),re(T)}else P(C);D=x(C)}if(D!==null)var G=!0;else{var Z=x(I);Z!==null&&r(se,Z.startTime-T),G=!1}return G}finally{D=null,j=A,B=!1}}var Ne=o;e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(R){R.callback=null},e.unstable_continueExecution=function(){V||B||(V=!0,t(ie))},e.unstable_getCurrentPriorityLevel=function(){return j},e.unstable_getFirstCallbackNode=function(){return x(C)},e.unstable_next=function(R){switch(j){case 1:case 2:case 3:var T=3;break;default:T=j}var A=j;j=T;try{return R()}finally{j=A}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=Ne,e.unstable_runWithPriority=function(R,T){switch(R){case 1:case 2:case 3:case 4:case 5:break;default:R=3}var A=j;j=R;try{return T()}finally{j=A}},e.unstable_scheduleCallback=function(R,T,A){var k=e.unstable_now();switch(typeof A=="object"&&A!==null?(A=A.delay,A=typeof A=="number"&&0k?(R.sortIndex=A,O(I,R),x(C)===null&&R===x(I)&&(W?n():W=!0,r(se,A-k))):(R.sortIndex=M,O(C,R),V||B||(V=!0,t(ie))),R},e.unstable_wrapCallback=function(R){var T=j;return function(){var A=j;j=T;try{return R.apply(this,arguments)}finally{j=A}}}})(F0);L0.exports=F0;/** @license React v17.0.2 + * react-dom.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 ks=g.exports,de=P0,Oe=L0.exports;function N(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,r=1;r"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Cx=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,_p=Object.prototype.hasOwnProperty,Sp={},bp={};function Ex(e){return _p.call(bp,e)?!0:_p.call(Sp,e)?!1:Cx.test(e)?bp[e]=!0:(Sp[e]=!0,!1)}function kx(e,t,r,n){if(r!==null&&r.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return n?!1:r!==null?!r.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function Rx(e,t,r,n){if(t===null||typeof t>"u"||kx(e,t,r,n))return!0;if(n)return!1;if(r!==null)switch(r.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function Be(e,t,r,n,o,i,l){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=n,this.attributeNamespace=o,this.mustUseProperty=r,this.propertyName=e,this.type=t,this.sanitizeURL=i,this.removeEmptyString=l}var Ie={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Ie[e]=new Be(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Ie[t]=new Be(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Ie[e]=new Be(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Ie[e]=new Be(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Ie[e]=new Be(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Ie[e]=new Be(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Ie[e]=new Be(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Ie[e]=new Be(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Ie[e]=new Be(e,5,!1,e.toLowerCase(),null,!1,!1)});var Af=/[\-:]([a-z])/g;function Vf(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(Af,Vf);Ie[t]=new Be(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(Af,Vf);Ie[t]=new Be(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(Af,Vf);Ie[t]=new Be(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Ie[e]=new Be(e,1,!1,e.toLowerCase(),null,!1,!1)});Ie.xlinkHref=new Be("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Ie[e]=new Be(e,1,!1,e.toLowerCase(),null,!0,!0)});function Hf(e,t,r,n){var o=Ie.hasOwnProperty(t)?Ie[t]:null,i=o!==null?o.type===0:n?!1:!(!(2a||o[l]!==i[a])return` +`+o[l].replace(" at new "," at ");while(1<=l&&0<=a);break}}}finally{Cu=!1,Error.prepareStackTrace=r}return(e=e?e.displayName||e.name:"")?Ao(e):""}function Ix(e){switch(e.tag){case 5:return Ao(e.type);case 16:return Ao("Lazy");case 13:return Ao("Suspense");case 19:return Ao("SuspenseList");case 0:case 2:case 15:return e=Zi(e.type,!1),e;case 11:return e=Zi(e.type.render,!1),e;case 22:return e=Zi(e.type._render,!1),e;case 1:return e=Zi(e.type,!0),e;default:return""}}function Nn(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case sr:return"Fragment";case Yr:return"Portal";case Uo:return"Profiler";case Bf:return"StrictMode";case Go:return"Suspense";case Bl:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Uf:return(e.displayName||"Context")+".Consumer";case Wf:return(e._context.displayName||"Context")+".Provider";case Rs:var t=e.render;return t=t.displayName||t.name||"",e.displayName||(t!==""?"ForwardRef("+t+")":"ForwardRef");case Is:return Nn(e.type);case Yf:return Nn(e._render);case Gf:t=e._payload,e=e._init;try{return Nn(e(t))}catch{}}return null}function Pr(e){switch(typeof e){case"boolean":case"number":case"object":case"string":case"undefined":return e;default:return""}}function H0(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Nx(e){var t=H0(e)?"checked":"value",r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),n=""+e[t];if(!e.hasOwnProperty(t)&&typeof r<"u"&&typeof r.get=="function"&&typeof r.set=="function"){var o=r.get,i=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return o.call(this)},set:function(l){n=""+l,i.call(this,l)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(l){n=""+l},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Ji(e){e._valueTracker||(e._valueTracker=Nx(e))}function B0(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var r=t.getValue(),n="";return e&&(n=H0(e)?e.checked?"true":"false":e.value),e=n,e!==r?(t.setValue(e),!0):!1}function Wl(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function xc(e,t){var r=t.checked;return de({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:r??e._wrapperState.initialChecked})}function Pp(e,t){var r=t.defaultValue==null?"":t.defaultValue,n=t.checked!=null?t.checked:t.defaultChecked;r=Pr(t.value!=null?t.value:r),e._wrapperState={initialChecked:n,initialValue:r,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function W0(e,t){t=t.checked,t!=null&&Hf(e,"checked",t,!1)}function Pc(e,t){W0(e,t);var r=Pr(t.value),n=t.type;if(r!=null)n==="number"?(r===0&&e.value===""||e.value!=r)&&(e.value=""+r):e.value!==""+r&&(e.value=""+r);else if(n==="submit"||n==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?$c(e,t.type,r):t.hasOwnProperty("defaultValue")&&$c(e,t.type,Pr(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function $p(e,t,r){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var n=t.type;if(!(n!=="submit"&&n!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,r||t===e.value||(e.value=t),e.defaultValue=t}r=e.name,r!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,r!==""&&(e.name=r)}function $c(e,t,r){(t!=="number"||Wl(e.ownerDocument)!==e)&&(r==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+r&&(e.defaultValue=""+r))}function zx(e){var t="";return ks.Children.forEach(e,function(r){r!=null&&(t+=r)}),t}function Oc(e,t){return e=de({children:void 0},t),(t=zx(t.children))&&(e.children=t),e}function zn(e,t,r,n){if(e=e.options,t){t={};for(var o=0;o=r.length))throw Error(N(93));r=r[0]}t=r}t==null&&(t=""),r=t}e._wrapperState={initialValue:Pr(r)}}function U0(e,t){var r=Pr(t.value),n=Pr(t.defaultValue);r!=null&&(r=""+r,r!==e.value&&(e.value=r),t.defaultValue==null&&e.defaultValue!==r&&(e.defaultValue=r)),n!=null&&(e.defaultValue=""+n)}function Cp(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}var Ec={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg"};function G0(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function kc(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?G0(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var el,Y0=function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,r,n,o){MSApp.execUnsafeLocalFunction(function(){return e(t,r,n,o)})}:e}(function(e,t){if(e.namespaceURI!==Ec.svg||"innerHTML"in e)e.innerHTML=t;else{for(el=el||document.createElement("div"),el.innerHTML=""+t.valueOf().toString()+"",t=el.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function si(e,t){if(t){var r=e.firstChild;if(r&&r===e.lastChild&&r.nodeType===3){r.nodeValue=t;return}}e.textContent=t}var Yo={animationIterationCount:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Dx=["Webkit","ms","Moz","O"];Object.keys(Yo).forEach(function(e){Dx.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Yo[t]=Yo[e]})});function X0(e,t,r){return t==null||typeof t=="boolean"||t===""?"":r||typeof t!="number"||t===0||Yo.hasOwnProperty(e)&&Yo[e]?(""+t).trim():t+"px"}function q0(e,t){e=e.style;for(var r in t)if(t.hasOwnProperty(r)){var n=r.indexOf("--")===0,o=X0(r,t[r],n);r==="float"&&(r="cssFloat"),n?e.setProperty(r,o):e[r]=o}}var Tx=de({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function Rc(e,t){if(t){if(Tx[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(N(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(N(60));if(!(typeof t.dangerouslySetInnerHTML=="object"&&"__html"in t.dangerouslySetInnerHTML))throw Error(N(61))}if(t.style!=null&&typeof t.style!="object")throw Error(N(62))}}function Ic(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}function Kf(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Nc=null,Dn=null,Tn=null;function Ep(e){if(e=Ri(e)){if(typeof Nc!="function")throw Error(N(280));var t=e.stateNode;t&&(t=js(t),Nc(e.stateNode,e.type,t))}}function K0(e){Dn?Tn?Tn.push(e):Tn=[e]:Dn=e}function Q0(){if(Dn){var e=Dn,t=Tn;if(Tn=Dn=null,Ep(e),t)for(e=0;en?0:1<r;r++)t.push(e);return t}function zs(e,t,r){e.pendingLanes|=t;var n=t-1;e.suspendedLanes&=n,e.pingedLanes&=n,e=e.eventTimes,t=31-$r(t),e[t]=r}var $r=Math.clz32?Math.clz32:Qx,qx=Math.log,Kx=Math.LN2;function Qx(e){return e===0?32:31-(qx(e)/Kx|0)|0}var Zx=Oe.unstable_UserBlockingPriority,Jx=Oe.unstable_runWithPriority,El=!0;function eP(e,t,r,n){Xr||Zf();var o=nd,i=Xr;Xr=!0;try{Z0(o,e,t,r,n)}finally{(Xr=i)||Jf()}}function tP(e,t,r,n){Jx(Zx,nd.bind(null,e,t,r,n))}function nd(e,t,r,n){if(El){var o;if((o=(t&4)===0)&&0=qo),Lp=String.fromCharCode(32),Fp=!1;function my(e,t){switch(e){case"keyup":return PP.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function vy(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var On=!1;function OP(e,t){switch(e){case"compositionend":return vy(t);case"keypress":return t.which!==32?null:(Fp=!0,Lp);case"textInput":return e=t.data,e===Lp&&Fp?null:e;default:return null}}function CP(e,t){if(On)return e==="compositionend"||!sd&&my(e,t)?(e=py(),kl=id=ur=null,On=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)return{node:r,offset:t-e};e=n}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=Bp(r)}}function _y(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?_y(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Up(){for(var e=window,t=Wl();t instanceof e.HTMLIFrameElement;){try{var r=typeof t.contentWindow.location.href=="string"}catch{r=!1}if(r)e=t.contentWindow;else break;t=Wl(e.document)}return t}function jc(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}var jP=Kt&&"documentMode"in document&&11>=document.documentMode,Cn=null,Lc=null,Qo=null,Fc=!1;function Gp(e,t,r){var n=r.window===r?r.document:r.nodeType===9?r:r.ownerDocument;Fc||Cn==null||Cn!==Wl(n)||(n=Cn,"selectionStart"in n&&jc(n)?n={start:n.selectionStart,end:n.selectionEnd}:(n=(n.ownerDocument&&n.ownerDocument.defaultView||window).getSelection(),n={anchorNode:n.anchorNode,anchorOffset:n.anchorOffset,focusNode:n.focusNode,focusOffset:n.focusOffset}),Qo&&gi(Qo,n)||(Qo=n,n=Xl(Lc,"onSelect"),0kn||(e.current=Vc[kn],Vc[kn]=null,kn--)}function he(e,t){kn++,Vc[kn]=e.current,e.current=t}var Or={},Fe=Nr(Or),Ye=Nr(!1),rn=Or;function Wn(e,t){var r=e.type.contextTypes;if(!r)return Or;var n=e.stateNode;if(n&&n.__reactInternalMemoizedUnmaskedChildContext===t)return n.__reactInternalMemoizedMaskedChildContext;var o={},i;for(i in r)o[i]=t[i];return n&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=o),o}function Xe(e){return e=e.childContextTypes,e!=null}function Ql(){fe(Ye),fe(Fe)}function tg(e,t,r){if(Fe.current!==Or)throw Error(N(168));he(Fe,t),he(Ye,r)}function Ey(e,t,r){var n=e.stateNode;if(e=t.childContextTypes,typeof n.getChildContext!="function")return r;n=n.getChildContext();for(var o in n)if(!(o in e))throw Error(N(108,Nn(t)||"Unknown",o));return de({},r,n)}function Il(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Or,rn=Fe.current,he(Fe,e),he(Ye,Ye.current),!0}function rg(e,t,r){var n=e.stateNode;if(!n)throw Error(N(169));r?(e=Ey(e,t,rn),n.__reactInternalMemoizedMergedChildContext=e,fe(Ye),fe(Fe),he(Fe,e)):fe(Ye),he(Ye,r)}var cd=null,Jr=null,AP=Oe.unstable_runWithPriority,fd=Oe.unstable_scheduleCallback,Hc=Oe.unstable_cancelCallback,VP=Oe.unstable_shouldYield,ng=Oe.unstable_requestPaint,Bc=Oe.unstable_now,HP=Oe.unstable_getCurrentPriorityLevel,Ls=Oe.unstable_ImmediatePriority,ky=Oe.unstable_UserBlockingPriority,Ry=Oe.unstable_NormalPriority,Iy=Oe.unstable_LowPriority,Ny=Oe.unstable_IdlePriority,Au={},BP=ng!==void 0?ng:function(){},Ht=null,Nl=null,Vu=!1,og=Bc(),je=1e4>og?Bc:function(){return Bc()-og};function Un(){switch(HP()){case Ls:return 99;case ky:return 98;case Ry:return 97;case Iy:return 96;case Ny:return 95;default:throw Error(N(332))}}function zy(e){switch(e){case 99:return Ls;case 98:return ky;case 97:return Ry;case 96:return Iy;case 95:return Ny;default:throw Error(N(332))}}function nn(e,t){return e=zy(e),AP(e,t)}function vi(e,t,r){return e=zy(e),fd(e,t,r)}function Mt(){if(Nl!==null){var e=Nl;Nl=null,Hc(e)}Dy()}function Dy(){if(!Vu&&Ht!==null){Vu=!0;var e=0;try{var t=Ht;nn(99,function(){for(;eP?($=x,x=null):$=x.sibling;var C=d(v,x,h[P],_);if(C===null){x===null&&(x=$);break}e&&x&&C.alternate===null&&t(v,x),m=i(C,m,P),O===null?b=C:O.sibling=C,O=C,x=$}if(P===h.length)return r(v,x),b;if(x===null){for(;PP?($=x,x=null):$=x.sibling;var I=d(v,x,C.value,_);if(I===null){x===null&&(x=$);break}e&&x&&I.alternate===null&&t(v,x),m=i(I,m,P),O===null?b=I:O.sibling=I,O=I,x=$}if(C.done)return r(v,x),b;if(x===null){for(;!C.done;P++,C=h.next())C=f(v,C.value,_),C!==null&&(m=i(C,m,P),O===null?b=C:O.sibling=C,O=C);return b}for(x=n(v,x);!C.done;P++,C=h.next())C=p(x,v,P,C.value,_),C!==null&&(e&&C.alternate!==null&&x.delete(C.key===null?P:C.key),m=i(C,m,P),O===null?b=C:O.sibling=C,O=C);return e&&x.forEach(function(z){return t(v,z)}),b}return function(v,m,h,_){var b=typeof h=="object"&&h!==null&&h.type===sr&&h.key===null;b&&(h=h.props.children);var O=typeof h=="object"&&h!==null;if(O)switch(h.$$typeof){case Fo:e:{for(O=h.key,b=m;b!==null;){if(b.key===O){switch(b.tag){case 7:if(h.type===sr){r(v,b.sibling),m=o(b,h.props.children),m.return=v,v=m;break e}break;default:if(b.elementType===h.type){r(v,b.sibling),m=o(b,h.props),m.ref=$o(v,b,h),m.return=v,v=m;break e}}r(v,b);break}else t(v,b);b=b.sibling}h.type===sr?(m=Vn(h.props.children,v.mode,_,h.key),m.return=v,v=m):(_=Ml(h.type,h.key,h.props,null,v.mode,_),_.ref=$o(v,m,h),_.return=v,v=_)}return l(v);case Yr:e:{for(b=h.key;m!==null;){if(m.key===b)if(m.tag===4&&m.stateNode.containerInfo===h.containerInfo&&m.stateNode.implementation===h.implementation){r(v,m.sibling),m=o(m,h.children||[]),m.return=v,v=m;break e}else{r(v,m);break}else t(v,m);m=m.sibling}m=Yu(h,v.mode,_),m.return=v,v=m}return l(v)}if(typeof h=="string"||typeof h=="number")return h=""+h,m!==null&&m.tag===6?(r(v,m.sibling),m=o(m,h),m.return=v,v=m):(r(v,m),m=Gu(h,v.mode,_),m.return=v,v=m),l(v);if(nl(h))return y(v,m,h,_);if(wo(h))return w(v,m,h,_);if(O&&ol(v,h),typeof h>"u"&&!b)switch(v.tag){case 1:case 22:case 0:case 11:case 15:throw Error(N(152,Nn(v.type)||"Component"))}return r(v,m)}}var ra=Fy(!0),Ay=Fy(!1),Ii={},It=Nr(Ii),yi=Nr(Ii),wi=Nr(Ii);function Kr(e){if(e===Ii)throw Error(N(174));return e}function Uc(e,t){switch(he(wi,t),he(yi,e),he(It,Ii),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:kc(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=kc(t,e)}fe(It),he(It,t)}function Gn(){fe(It),fe(yi),fe(wi)}function ug(e){Kr(wi.current);var t=Kr(It.current),r=kc(t,e.type);t!==r&&(he(yi,e),he(It,r))}function md(e){yi.current===e&&(fe(It),fe(yi))}var ve=Nr(0);function na(e){for(var t=e;t!==null;){if(t.tag===13){var r=t.memoizedState;if(r!==null&&(r=r.dehydrated,r===null||r.data==="$?"||r.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if((t.flags&64)!==0)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var Gt=null,fr=null,Nt=!1;function Vy(e,t){var r=ft(5,null,null,0);r.elementType="DELETED",r.type="DELETED",r.stateNode=t,r.return=e,r.flags=8,e.lastEffect!==null?(e.lastEffect.nextEffect=r,e.lastEffect=r):e.firstEffect=e.lastEffect=r}function cg(e,t){switch(e.tag){case 5:var r=e.type;return t=t.nodeType!==1||r.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,!0):!1;case 13:return!1;default:return!1}}function Gc(e){if(Nt){var t=fr;if(t){var r=t;if(!cg(e,t)){if(t=Mn(r.nextSibling),!t||!cg(e,t)){e.flags=e.flags&-1025|2,Nt=!1,Gt=e;return}Vy(Gt,r)}Gt=e,fr=Mn(t.firstChild)}else e.flags=e.flags&-1025|2,Nt=!1,Gt=e}}function fg(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;Gt=e}function il(e){if(e!==Gt)return!1;if(!Nt)return fg(e),Nt=!0,!1;var t=e.type;if(e.tag!==5||t!=="head"&&t!=="body"&&!Ac(t,e.memoizedProps))for(t=fr;t;)Vy(e,t),t=Mn(t.nextSibling);if(fg(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(N(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var r=e.data;if(r==="/$"){if(t===0){fr=Mn(e.nextSibling);break e}t--}else r!=="$"&&r!=="$!"&&r!=="$?"||t++}e=e.nextSibling}fr=null}}else fr=Gt?Mn(e.stateNode.nextSibling):null;return!0}function Hu(){fr=Gt=null,Nt=!1}var Ln=[];function vd(){for(var e=0;ei))throw Error(N(301));i+=1,ke=Me=null,t.updateQueue=null,Zo.current=XP,e=r(n,o)}while(Jo)}if(Zo.current=sa,t=Me!==null&&Me.next!==null,_i=0,ke=Me=ye=null,oa=!1,t)throw Error(N(300));return e}function Qr(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return ke===null?ye.memoizedState=ke=e:ke=ke.next=e,ke}function fn(){if(Me===null){var e=ye.alternate;e=e!==null?e.memoizedState:null}else e=Me.next;var t=ke===null?ye.memoizedState:ke.next;if(t!==null)ke=t,Me=e;else{if(e===null)throw Error(N(310));Me=e,e={memoizedState:Me.memoizedState,baseState:Me.baseState,baseQueue:Me.baseQueue,queue:Me.queue,next:null},ke===null?ye.memoizedState=ke=e:ke=ke.next=e}return ke}function kt(e,t){return typeof t=="function"?t(e):t}function Oo(e){var t=fn(),r=t.queue;if(r===null)throw Error(N(311));r.lastRenderedReducer=e;var n=Me,o=n.baseQueue,i=r.pending;if(i!==null){if(o!==null){var l=o.next;o.next=i.next,i.next=l}n.baseQueue=o=i,r.pending=null}if(o!==null){o=o.next,n=n.baseState;var a=l=i=null,s=o;do{var u=s.lane;if((_i&u)===u)a!==null&&(a=a.next={lane:0,action:s.action,eagerReducer:s.eagerReducer,eagerState:s.eagerState,next:null}),n=s.eagerReducer===e?s.eagerState:e(n,s.action);else{var c={lane:u,action:s.action,eagerReducer:s.eagerReducer,eagerState:s.eagerState,next:null};a===null?(l=a=c,i=n):a=a.next=c,ye.lanes|=u,Ni|=u}s=s.next}while(s!==null&&s!==o);a===null?i=n:a.next=l,ct(n,t.memoizedState)||(xt=!0),t.memoizedState=n,t.baseState=i,t.baseQueue=a,r.lastRenderedState=n}return[t.memoizedState,r.dispatch]}function Co(e){var t=fn(),r=t.queue;if(r===null)throw Error(N(311));r.lastRenderedReducer=e;var n=r.dispatch,o=r.pending,i=t.memoizedState;if(o!==null){r.pending=null;var l=o=o.next;do i=e(i,l.action),l=l.next;while(l!==o);ct(i,t.memoizedState)||(xt=!0),t.memoizedState=i,t.baseQueue===null&&(t.baseState=i),r.lastRenderedState=i}return[i,n]}function dg(e,t,r){var n=t._getVersion;n=n(t._source);var o=t._workInProgressVersionPrimary;if(o!==null?e=o===n:(e=e.mutableReadLanes,(e=(_i&e)===e)&&(t._workInProgressVersionPrimary=n,Ln.push(t))),e)return r(t._source);throw Ln.push(t),Error(N(350))}function Hy(e,t,r,n){var o=He;if(o===null)throw Error(N(349));var i=t._getVersion,l=i(t._source),a=Zo.current,s=a.useState(function(){return dg(o,t,r)}),u=s[1],c=s[0];s=ke;var f=e.memoizedState,d=f.refs,p=d.getSnapshot,y=f.source;f=f.subscribe;var w=ye;return e.memoizedState={refs:d,source:t,subscribe:n},a.useEffect(function(){d.getSnapshot=r,d.setSnapshot=u;var v=i(t._source);if(!ct(l,v)){v=r(t._source),ct(c,v)||(u(v),v=wr(w),o.mutableReadLanes|=v&o.pendingLanes),v=o.mutableReadLanes,o.entangledLanes|=v;for(var m=o.entanglements,h=v;0r?98:r,function(){e(!0)}),nn(97<\/script>",e=e.removeChild(e.firstChild)):typeof n.is=="string"?e=l.createElement(r,{is:n.is}):(e=l.createElement(r),r==="select"&&(l=e,n.multiple?l.multiple=!0:n.size&&(l.size=n.size))):e=l.createElementNS(e,r),e[cr]=t,e[Kl]=n,Qy(e,t,!1,!1),t.stateNode=e,l=Ic(r,n),r){case"dialog":ce("cancel",e),ce("close",e),o=n;break;case"iframe":case"object":case"embed":ce("load",e),o=n;break;case"video":case"audio":for(o=0;orf&&(t.flags|=64,i=!0,ko(n,!1),t.lanes=33554432)}else{if(!i)if(e=na(l),e!==null){if(t.flags|=64,i=!0,r=e.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),ko(n,!0),n.tail===null&&n.tailMode==="hidden"&&!l.alternate&&!Nt)return t=t.lastEffect=n.lastEffect,t!==null&&(t.nextEffect=null),null}else 2*je()-n.renderingStartTime>rf&&r!==1073741824&&(t.flags|=64,i=!0,ko(n,!1),t.lanes=33554432);n.isBackwards?(l.sibling=t.child,t.child=l):(r=n.last,r!==null?r.sibling=l:t.child=l,n.last=l)}return n.tail!==null?(r=n.tail,n.rendering=r,n.tail=r.sibling,n.lastEffect=t.lastEffect,n.renderingStartTime=je(),r.sibling=null,t=ve.current,he(ve,i?t&1|2:t&1),r):null;case 23:case 24:return Od(),e!==null&&e.memoizedState!==null!=(t.memoizedState!==null)&&n.mode!=="unstable-defer-without-hiding"&&(t.flags|=4),null}throw Error(N(156,t.tag))}function QP(e){switch(e.tag){case 1:Xe(e.type)&&Ql();var t=e.flags;return t&4096?(e.flags=t&-4097|64,e):null;case 3:if(Gn(),fe(Ye),fe(Fe),vd(),t=e.flags,(t&64)!==0)throw Error(N(285));return e.flags=t&-4097|64,e;case 5:return md(e),null;case 13:return fe(ve),t=e.flags,t&4096?(e.flags=t&-4097|64,e):null;case 19:return fe(ve),null;case 4:return Gn(),null;case 10:return pd(e),null;case 23:case 24:return Od(),null;default:return null}}function bd(e,t){try{var r="",n=t;do r+=Ix(n),n=n.return;while(n);var o=r}catch(i){o=` +Error generating stack: `+i.message+` +`+i.stack}return{value:e,source:t,stack:o}}function Qc(e,t){try{console.error(t.value)}catch(r){setTimeout(function(){throw r})}}var ZP=typeof WeakMap=="function"?WeakMap:Map;function e1(e,t,r){r=hr(-1,r),r.tag=3,r.payload={element:null};var n=t.value;return r.callback=function(){ca||(ca=!0,nf=n),Qc(e,t)},r}function t1(e,t,r){r=hr(-1,r),r.tag=3;var n=e.type.getDerivedStateFromError;if(typeof n=="function"){var o=t.value;r.payload=function(){return Qc(e,t),n(o)}}var i=e.stateNode;return i!==null&&typeof i.componentDidCatch=="function"&&(r.callback=function(){typeof n!="function"&&(Rt===null?Rt=new Set([this]):Rt.add(this),Qc(e,t));var l=t.stack;this.componentDidCatch(t.value,{componentStack:l!==null?l:""})}),r}var JP=typeof WeakSet=="function"?WeakSet:Set;function $g(e){var t=e.ref;if(t!==null)if(typeof t=="function")try{t(null)}catch(r){Sr(e,r)}else t.current=null}function e$(e,t){switch(t.tag){case 0:case 11:case 15:case 22:return;case 1:if(t.flags&256&&e!==null){var r=e.memoizedProps,n=e.memoizedState;e=t.stateNode,t=e.getSnapshotBeforeUpdate(t.elementType===t.type?r:bt(t.type,r),n),e.__reactInternalSnapshotBeforeUpdate=t}return;case 3:t.flags&256&&ud(t.stateNode.containerInfo);return;case 5:case 6:case 4:case 17:return}throw Error(N(163))}function t$(e,t,r){switch(r.tag){case 0:case 11:case 15:case 22:if(t=r.updateQueue,t=t!==null?t.lastEffect:null,t!==null){e=t=t.next;do{if((e.tag&3)===3){var n=e.create;e.destroy=n()}e=e.next}while(e!==t)}if(t=r.updateQueue,t=t!==null?t.lastEffect:null,t!==null){e=t=t.next;do{var o=e;n=o.next,o=o.tag,(o&4)!==0&&(o&1)!==0&&(c1(r,e),u$(r,e)),e=n}while(e!==t)}return;case 1:e=r.stateNode,r.flags&4&&(t===null?e.componentDidMount():(n=r.elementType===r.type?t.memoizedProps:bt(r.type,t.memoizedProps),e.componentDidUpdate(n,t.memoizedState,e.__reactInternalSnapshotBeforeUpdate))),t=r.updateQueue,t!==null&&lg(r,t,e);return;case 3:if(t=r.updateQueue,t!==null){if(e=null,r.child!==null)switch(r.child.tag){case 5:e=r.child.stateNode;break;case 1:e=r.child.stateNode}lg(r,t,e)}return;case 5:e=r.stateNode,t===null&&r.flags&4&&Oy(r.type,r.memoizedProps)&&e.focus();return;case 6:return;case 4:return;case 12:return;case 13:r.memoizedState===null&&(r=r.alternate,r!==null&&(r=r.memoizedState,r!==null&&(r=r.dehydrated,r!==null&&iy(r))));return;case 19:case 17:case 20:case 21:case 23:case 24:return}throw Error(N(163))}function Og(e,t){for(var r=e;;){if(r.tag===5){var n=r.stateNode;if(t)n=n.style,typeof n.setProperty=="function"?n.setProperty("display","none","important"):n.display="none";else{n=r.stateNode;var o=r.memoizedProps.style;o=o!=null&&o.hasOwnProperty("display")?o.display:null,n.style.display=X0("display",o)}}else if(r.tag===6)r.stateNode.nodeValue=t?"":r.memoizedProps;else if((r.tag!==23&&r.tag!==24||r.memoizedState===null||r===e)&&r.child!==null){r.child.return=r,r=r.child;continue}if(r===e)break;for(;r.sibling===null;){if(r.return===null||r.return===e)return;r=r.return}r.sibling.return=r.return,r=r.sibling}}function Cg(e,t){if(Jr&&typeof Jr.onCommitFiberUnmount=="function")try{Jr.onCommitFiberUnmount(cd,t)}catch{}switch(t.tag){case 0:case 11:case 14:case 15:case 22:if(e=t.updateQueue,e!==null&&(e=e.lastEffect,e!==null)){var r=e=e.next;do{var n=r,o=n.destroy;if(n=n.tag,o!==void 0)if((n&4)!==0)c1(t,r);else{n=t;try{o()}catch(i){Sr(n,i)}}r=r.next}while(r!==e)}break;case 1:if($g(t),e=t.stateNode,typeof e.componentWillUnmount=="function")try{e.props=t.memoizedProps,e.state=t.memoizedState,e.componentWillUnmount()}catch(i){Sr(t,i)}break;case 5:$g(t);break;case 4:r1(e,t)}}function Eg(e){e.alternate=null,e.child=null,e.dependencies=null,e.firstEffect=null,e.lastEffect=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.return=null,e.updateQueue=null}function kg(e){return e.tag===5||e.tag===3||e.tag===4}function Rg(e){e:{for(var t=e.return;t!==null;){if(kg(t))break e;t=t.return}throw Error(N(160))}var r=t;switch(t=r.stateNode,r.tag){case 5:var n=!1;break;case 3:t=t.containerInfo,n=!0;break;case 4:t=t.containerInfo,n=!0;break;default:throw Error(N(161))}r.flags&16&&(si(t,""),r.flags&=-17);e:t:for(r=e;;){for(;r.sibling===null;){if(r.return===null||kg(r.return)){r=null;break e}r=r.return}for(r.sibling.return=r.return,r=r.sibling;r.tag!==5&&r.tag!==6&&r.tag!==18;){if(r.flags&2||r.child===null||r.tag===4)continue t;r.child.return=r,r=r.child}if(!(r.flags&2)){r=r.stateNode;break e}}n?Zc(e,r,t):Jc(e,r,t)}function Zc(e,t,r){var n=e.tag,o=n===5||n===6;if(o)e=o?e.stateNode:e.stateNode.instance,t?r.nodeType===8?r.parentNode.insertBefore(e,t):r.insertBefore(e,t):(r.nodeType===8?(t=r.parentNode,t.insertBefore(e,r)):(t=r,t.appendChild(e)),r=r._reactRootContainer,r!=null||t.onclick!==null||(t.onclick=ql));else if(n!==4&&(e=e.child,e!==null))for(Zc(e,t,r),e=e.sibling;e!==null;)Zc(e,t,r),e=e.sibling}function Jc(e,t,r){var n=e.tag,o=n===5||n===6;if(o)e=o?e.stateNode:e.stateNode.instance,t?r.insertBefore(e,t):r.appendChild(e);else if(n!==4&&(e=e.child,e!==null))for(Jc(e,t,r),e=e.sibling;e!==null;)Jc(e,t,r),e=e.sibling}function r1(e,t){for(var r=t,n=!1,o,i;;){if(!n){n=r.return;e:for(;;){if(n===null)throw Error(N(160));switch(o=n.stateNode,n.tag){case 5:i=!1;break e;case 3:o=o.containerInfo,i=!0;break e;case 4:o=o.containerInfo,i=!0;break e}n=n.return}n=!0}if(r.tag===5||r.tag===6){e:for(var l=e,a=r,s=a;;)if(Cg(l,s),s.child!==null&&s.tag!==4)s.child.return=s,s=s.child;else{if(s===a)break e;for(;s.sibling===null;){if(s.return===null||s.return===a)break e;s=s.return}s.sibling.return=s.return,s=s.sibling}i?(l=o,a=r.stateNode,l.nodeType===8?l.parentNode.removeChild(a):l.removeChild(a)):o.removeChild(r.stateNode)}else if(r.tag===4){if(r.child!==null){o=r.stateNode.containerInfo,i=!0,r.child.return=r,r=r.child;continue}}else if(Cg(e,r),r.child!==null){r.child.return=r,r=r.child;continue}if(r===t)break;for(;r.sibling===null;){if(r.return===null||r.return===t)return;r=r.return,r.tag===4&&(n=!1)}r.sibling.return=r.return,r=r.sibling}}function Uu(e,t){switch(t.tag){case 0:case 11:case 14:case 15:case 22:var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var n=r=r.next;do(n.tag&3)===3&&(e=n.destroy,n.destroy=void 0,e!==void 0&&e()),n=n.next;while(n!==r)}return;case 1:return;case 5:if(r=t.stateNode,r!=null){n=t.memoizedProps;var o=e!==null?e.memoizedProps:n;e=t.type;var i=t.updateQueue;if(t.updateQueue=null,i!==null){for(r[Kl]=n,e==="input"&&n.type==="radio"&&n.name!=null&&W0(r,n),Ic(e,o),t=Ic(e,n),o=0;oo&&(o=l),r&=~i}if(r=o,r=je()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*n$(r/1960))-r,10 component higher in the tree to provide a loading indicator or placeholder to display.`)}Re!==5&&(Re=2),s=bd(s,a),d=l;do{switch(d.tag){case 3:i=s,d.flags|=4096,t&=-t,d.lanes|=t;var O=e1(d,i,t);ig(d,O);break e;case 1:i=s;var x=d.type,P=d.stateNode;if((d.flags&64)===0&&(typeof x.getDerivedStateFromError=="function"||P!==null&&typeof P.componentDidCatch=="function"&&(Rt===null||!Rt.has(P)))){d.flags|=4096,t&=-t,d.lanes|=t;var $=t1(d,i,t);ig(d,$);break e}}d=d.return}while(d!==null)}u1(r)}catch(C){t=C,Se===r&&r!==null&&(Se=r=r.return);continue}break}while(1)}function a1(){var e=ua.current;return ua.current=sa,e===null?sa:e}function Bo(e,t){var r=Y;Y|=16;var n=a1();He===e&&Le===t||An(e,t);do try{i$();break}catch(o){l1(e,o)}while(1);if(dd(),Y=r,ua.current=n,Se!==null)throw Error(N(261));return He=null,Le=0,Re}function i$(){for(;Se!==null;)s1(Se)}function l$(){for(;Se!==null&&!VP();)s1(Se)}function s1(e){var t=f1(e.alternate,e,on);e.memoizedProps=e.pendingProps,t===null?u1(e):Se=t,xd.current=null}function u1(e){var t=e;do{var r=t.alternate;if(e=t.return,(t.flags&2048)===0){if(r=KP(r,t,on),r!==null){Se=r;return}if(r=t,r.tag!==24&&r.tag!==23||r.memoizedState===null||(on&1073741824)!==0||(r.mode&4)===0){for(var n=0,o=r.child;o!==null;)n|=o.lanes|o.childLanes,o=o.sibling;r.childLanes=n}e!==null&&(e.flags&2048)===0&&(e.firstEffect===null&&(e.firstEffect=t.firstEffect),t.lastEffect!==null&&(e.lastEffect!==null&&(e.lastEffect.nextEffect=t.firstEffect),e.lastEffect=t.lastEffect),1l&&(a=l,l=O,O=a),a=Wp(h,O),i=Wp(h,l),a&&i&&(b.rangeCount!==1||b.anchorNode!==a.node||b.anchorOffset!==a.offset||b.focusNode!==i.node||b.focusOffset!==i.offset)&&(_=_.createRange(),_.setStart(a.node,a.offset),b.removeAllRanges(),O>l?(b.addRange(_),b.extend(i.node,i.offset)):(_.setEnd(i.node,i.offset),b.addRange(_)))))),_=[],b=h;b=b.parentNode;)b.nodeType===1&&_.push({element:b,left:b.scrollLeft,top:b.scrollTop});for(typeof h.focus=="function"&&h.focus(),h=0;h<_.length;h++)b=_[h],b.element.scrollLeft=b.left,b.element.scrollTop=b.top}El=!!ju,Lu=ju=null,e.current=r,L=n;do try{for(h=e;L!==null;){var x=L.flags;if(x&36&&t$(h,L.alternate,L),x&128){_=void 0;var P=L.ref;if(P!==null){var $=L.stateNode;switch(L.tag){case 5:_=$;break;default:_=$}typeof P=="function"?P(_):P.current=_}}L=L.nextEffect}}catch(C){if(L===null)throw Error(N(330));Sr(L,C),L=L.nextEffect}while(L!==null);L=null,BP(),Y=o}else e.current=r;if(Cr)Cr=!1,ei=e,Ho=t;else for(L=n;L!==null;)t=L.nextEffect,L.nextEffect=null,L.flags&8&&(x=L,x.sibling=null,x.stateNode=null),L=t;if(n=e.pendingLanes,n===0&&(Rt=null),n===1?e===af?ti++:(ti=0,af=e):ti=0,r=r.stateNode,Jr&&typeof Jr.onCommitFiberRoot=="function")try{Jr.onCommitFiberRoot(cd,r,void 0,(r.current.flags&64)===64)}catch{}if(gt(e,je()),ca)throw ca=!1,e=nf,nf=null,e;return(Y&8)!==0||Mt(),null}function s$(){for(;L!==null;){var e=L.alternate;Tl||ri===null||((L.flags&8)!==0?Rp(L,ri)&&(Tl=!0):L.tag===13&&r$(e,L)&&Rp(L,ri)&&(Tl=!0));var t=L.flags;(t&256)!==0&&e$(e,L),(t&512)===0||Cr||(Cr=!0,vi(97,function(){return zr(),null})),L=L.nextEffect}}function zr(){if(Ho!==90){var e=97je()-$d?An(e,0):Pd|=r),gt(e,t)}function d$(e,t){var r=e.stateNode;r!==null&&r.delete(t),t=0,t===0&&(t=e.mode,(t&2)===0?t=1:(t&4)===0?t=Un()===99?1:2:(Wt===0&&(Wt=to),t=xn(62914560&~Wt),t===0&&(t=4194304))),r=tt(),e=Vs(e,t),e!==null&&(zs(e,t,r),gt(e,r))}var f1;f1=function(e,t,r){var n=t.lanes;if(e!==null)if(e.memoizedProps!==t.pendingProps||Ye.current)xt=!0;else if((r&n)!==0)xt=(e.flags&16384)!==0;else{switch(xt=!1,t.tag){case 3:yg(t),Hu();break;case 5:ug(t);break;case 1:Xe(t.type)&&Il(t);break;case 4:Uc(t,t.stateNode.containerInfo);break;case 10:n=t.memoizedProps.value;var o=t.type._context;he(Zl,o._currentValue),o._currentValue=n;break;case 13:if(t.memoizedState!==null)return(r&t.child.childLanes)!==0?wg(e,t,r):(he(ve,ve.current&1),t=Yt(e,t,r),t!==null?t.sibling:null);he(ve,ve.current&1);break;case 19:if(n=(r&t.childLanes)!==0,(e.flags&64)!==0){if(n)return Pg(e,t,r);t.flags|=64}if(o=t.memoizedState,o!==null&&(o.rendering=null,o.tail=null,o.lastEffect=null),he(ve,ve.current),n)break;return null;case 23:case 24:return t.lanes=0,Bu(e,t,r)}return Yt(e,t,r)}else xt=!1;switch(t.lanes=0,t.tag){case 2:if(n=t.type,e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2),e=t.pendingProps,o=Wn(t,Fe.current),jn(t,r),o=yd(null,t,n,e,o,r),t.flags|=1,typeof o=="object"&&o!==null&&typeof o.render=="function"&&o.$$typeof===void 0){if(t.tag=1,t.memoizedState=null,t.updateQueue=null,Xe(n)){var i=!0;Il(t)}else i=!1;t.memoizedState=o.state!==null&&o.state!==void 0?o.state:null,gd(t);var l=n.getDerivedStateFromProps;typeof l=="function"&&ta(t,n,l,e),o.updater=Fs,t.stateNode=o,o._reactInternals=t,Wc(t,n,e,r),t=qc(null,t,n,!0,i,r)}else t.tag=0,Ue(null,t,o,r),t=t.child;return t;case 16:o=t.elementType;e:{switch(e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2),e=t.pendingProps,i=o._init,o=i(o._payload),t.type=o,i=t.tag=g$(o),e=bt(o,e),i){case 0:t=Xc(null,t,o,e,r);break e;case 1:t=hg(null,t,o,e,r);break e;case 11:t=mg(null,t,o,e,r);break e;case 14:t=vg(null,t,o,bt(o.type,e),n,r);break e}throw Error(N(306,o,""))}return t;case 0:return n=t.type,o=t.pendingProps,o=t.elementType===n?o:bt(n,o),Xc(e,t,n,o,r);case 1:return n=t.type,o=t.pendingProps,o=t.elementType===n?o:bt(n,o),hg(e,t,n,o,r);case 3:if(yg(t),n=t.updateQueue,e===null||n===null)throw Error(N(282));if(n=t.pendingProps,o=t.memoizedState,o=o!==null?o.element:null,My(e,t),hi(t,n,null,r),n=t.memoizedState.element,n===o)Hu(),t=Yt(e,t,r);else{if(o=t.stateNode,(i=o.hydrate)&&(fr=Mn(t.stateNode.containerInfo.firstChild),Gt=t,i=Nt=!0),i){if(e=o.mutableSourceEagerHydrationData,e!=null)for(o=0;o"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(p1)}catch(e){console.error(e)}}p1(),Ei.exports=ht;var S$=Ei.exports;function da(e,t){let r=e;for(;(r=r.parentElement)&&!r.matches(t););return r}function b$(e,t,r){for(let n=e-1;n>=0;n-=1)if(!t[n].disabled)return n;if(r){for(let n=t.length-1;n>-1;n-=1)if(!t[n].disabled)return n}return e}function x$(e,t,r){for(let n=e+1;n{var s;r?.(a);const u=Array.from(((s=da(a.currentTarget,e))==null?void 0:s.querySelectorAll(t))||[]).filter(w=>P$(a.currentTarget,w,e)),c=u.findIndex(w=>a.currentTarget===w),f=x$(c,u,n),d=b$(c,u,n),p=i==="rtl"?d:f,y=i==="rtl"?f:d;switch(a.key){case"ArrowRight":{l==="horizontal"&&(a.stopPropagation(),a.preventDefault(),u[p].focus(),o&&u[p].click());break}case"ArrowLeft":{l==="horizontal"&&(a.stopPropagation(),a.preventDefault(),u[y].focus(),o&&u[y].click());break}case"ArrowUp":{l==="vertical"&&(a.stopPropagation(),a.preventDefault(),u[d].focus(),o&&u[d].click());break}case"ArrowDown":{l==="vertical"&&(a.stopPropagation(),a.preventDefault(),u[f].focus(),o&&u[f].click());break}case"Home":{a.stopPropagation(),a.preventDefault(),!u[0].disabled&&u[0].focus();break}case"End":{a.stopPropagation(),a.preventDefault();const w=u.length-1;!u[w].disabled&&u[w].focus();break}}}}function $$(e,t,r){var n;return r?Array.from(((n=da(r,t))==null?void 0:n.querySelectorAll(e))||[]).findIndex(o=>o===r):null}var Bs={exports:{}},Di={};/** @license React v17.0.2 + * react-jsx-runtime.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 O$=g.exports,m1=60103;Di.Fragment=60107;if(typeof Symbol=="function"&&Symbol.for){var Dg=Symbol.for;m1=Dg("react.element"),Di.Fragment=Dg("react.fragment")}var C$=O$.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,E$=Object.prototype.hasOwnProperty,k$={key:!0,ref:!0,__self:!0,__source:!0};function v1(e,t,r){var n,o={},i=null,l=null;r!==void 0&&(i=""+r),t.key!==void 0&&(i=""+t.key),t.ref!==void 0&&(l=t.ref);for(n in t)E$.call(t,n)&&!k$.hasOwnProperty(n)&&(o[n]=t[n]);if(e&&e.defaultProps)for(n in t=e.defaultProps,t)o[n]===void 0&&(o[n]=t[n]);return{$$typeof:m1,type:e,key:i,ref:l,props:o,_owner:C$.current}}Di.jsx=v1;Di.jsxs=v1;Bs.exports=Di;const S=Bs.exports.jsx,U=Bs.exports.jsxs,it=Bs.exports.Fragment;function Id(e){const t=g.exports.createContext(null);return[({children:o,value:i})=>S(t.Provider,{value:i,children:o}),()=>{const o=g.exports.useContext(t);if(o===null)throw new Error(e);return o}]}function Si(e){return Array.isArray(e)?e:[e]}function Tg(e,t){return r=>{if(typeof r!="string"||r.trim().length===0)throw new Error(t);return`${e}-${r}`}}function Ti(e){return Array.isArray(e)||e===null?!1:typeof e=="object"?e.type!==E.Fragment:!1}const R$=()=>{};function I$(e,t={active:!0}){return typeof e!="function"||!t.active?R$:r=>{var n;r.key==="Escape"&&(e(),(n=t.onTrigger)==null||n.call(t))}}function Xt(e,t){return r=>{e?.(r),t?.(r)}}function N$(){const[e,t]=g.exports.useState(-1);return[e,{setHovered:t,resetHovered:()=>t(-1)}]}function z$({data:e}){const t=[],r=[],n=e.reduce((o,i,l)=>(i.group?o[i.group]?o[i.group].push(l):o[i.group]=[l]:r.push(l),o),{});return Object.keys(n).forEach(o=>{t.push(...n[o].map(i=>e[i]))}),t.push(...r.map(o=>e[o])),t}function D$(e,t){window.dispatchEvent(new CustomEvent(e,{detail:t}))}const T$=typeof window<"u"?g.exports.useLayoutEffect:g.exports.useEffect;function M$(e){function t(n){const o=Object.keys(n).reduce((i,l)=>(i[`${e}:${l}`]=a=>n[l](a.detail),i),{});T$(()=>(Object.keys(o).forEach(i=>{window.removeEventListener(i,o[i]),window.addEventListener(i,o[i])}),()=>Object.keys(o).forEach(i=>{window.removeEventListener(i,o[i])})),[])}function r(n){return(...o)=>D$(`${e}:${String(n)}`,o[0])}return[t,r]}function h1(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t({fontFamily:e.fontFamily||"sans-serif"})}function L$(e){return()=>({WebkitTapHighlightColor:"transparent","&:focus":{outlineOffset:2,outline:e.focusRing==="always"||e.focusRing==="auto"?`2px solid ${e.colors[e.primaryColor][e.colorScheme==="dark"?7:5]}`:"none"},"&:focus:not(:focus-visible)":{outline:e.focusRing==="auto"||e.focusRing==="never"?"none":void 0}})}function Mi(e){return t=>typeof e.primaryShade=="number"?e.primaryShade:e.primaryShade[t||e.colorScheme]}function Nd(e){const t=Mi(e);return(r,n,o=!0,i=!0)=>{if(typeof r=="string"&&r.includes(".")){const[a,s]=r.split("."),u=parseInt(s,10);if(a in e.colors&&u>=0&&u<10)return e.colors[a][typeof n=="number"&&!i?n:u]}const l=typeof n=="number"?n:t();return r in e.colors?e.colors[r][l]:o?e.colors[e.primaryColor][l]:r}}function _1(e){let t="";for(let r=1;r{const o={from:n?.from||e.defaultGradient.from,to:n?.to||e.defaultGradient.to,deg:n?.deg||e.defaultGradient.deg};return`linear-gradient(${o.deg}deg, ${t(o.from,r(),!1)} 0%, ${t(o.to,r(),!1)} 100%)`}}function zd(e){if(typeof e.size=="number")return e.size;const t=e.sizes[e.size];return t!==void 0?t:e.size||e.sizes.md}function V$(e){return t=>`@media (min-width: ${zd({size:t,sizes:e.breakpoints})+1}px)`}function H$(e){return t=>`@media (max-width: ${zd({size:t,sizes:e.breakpoints})}px)`}function B$(e){return/^#?([0-9A-F]{3}){1,2}$/i.test(e)}function W$(e){let t=e.replace("#","");if(t.length===3){const l=t.split("");t=[l[0],l[0],l[1],l[1],l[2],l[2]].join("")}const r=parseInt(t,16),n=r>>16&255,o=r>>8&255,i=r&255;return{r:n,g:o,b:i,a:1}}function U$(e){const[t,r,n,o]=e.replace(/[^0-9,.]/g,"").split(",").map(Number);return{r:t,g:r,b:n,a:o||1}}function Dd(e){return B$(e)?W$(e):e.startsWith("rgb")?U$(e):{r:0,g:0,b:0,a:1}}function Pn(e,t){if(typeof e!="string"||t>1||t<0)return"rgba(0, 0, 0, 1)";const{r,g:n,b:o}=Dd(e);return`rgba(${r}, ${n}, ${o}, ${t})`}function G$(e=0){return{position:"absolute",top:e,right:e,left:e,bottom:e}}function Y$(e,t){const{r,g:n,b:o,a:i}=Dd(e),l=1-t,a=s=>Math.round(s*l);return`rgba(${a(r)}, ${a(n)}, ${a(o)}, ${i})`}function X$(e,t){const{r,g:n,b:o,a:i}=Dd(e),l=a=>Math.round(a+(255-a)*t);return`rgba(${l(r)}, ${l(n)}, ${l(o)}, ${i})`}function q$(e){return t=>{if(typeof t=="number")return t;const r=typeof e.defaultRadius=="number"?e.defaultRadius:e.radius[e.defaultRadius]||e.defaultRadius;return e.radius[t]||t||r}}function K$(e,t){if(typeof e=="string"&&e.includes(".")){const[r,n]=e.split("."),o=parseInt(n,10);if(r in t.colors&&o>=0&&o<10)return{isSplittedColor:!0,key:r,shade:o}}return{isSplittedColor:!1}}function Q$(e){const t=Nd(e),r=Mi(e),n=S1(e);return({variant:o,color:i,gradient:l,primaryFallback:a})=>{const s=K$(i,e);if(o==="light")return{border:"transparent",background:Pn(t(i,e.colorScheme==="dark"?8:0,a,!1),e.colorScheme==="dark"?.2:1),color:i==="dark"?e.colorScheme==="dark"?e.colors.dark[0]:e.colors.dark[9]:t(i,e.colorScheme==="dark"?2:r("light")),hover:Pn(t(i,e.colorScheme==="dark"?7:1,a,!1),e.colorScheme==="dark"?.25:.65)};if(o==="default")return{border:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4],background:e.colorScheme==="dark"?e.colors.dark[6]:e.white,color:e.colorScheme==="dark"?e.white:e.black,hover:e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[0]};if(o==="white")return{border:"transparent",background:e.white,color:t(i,r()),hover:null};if(o==="outline")return{border:t(i,e.colorScheme==="dark"?5:r("light")),background:"transparent",color:t(i,e.colorScheme==="dark"?5:r("light")),hover:e.colorScheme==="dark"?Pn(t(i,5,a,!1),.05):Pn(t(i,0,a,!1),.35)};if(o==="gradient")return{background:n(l),color:e.white,border:"transparent",hover:null};if(o==="subtle")return{border:"transparent",background:"transparent",color:i==="dark"?e.colorScheme==="dark"?e.colors.dark[0]:e.colors.dark[9]:t(i,e.colorScheme==="dark"?2:r("light")),hover:Pn(t(i,e.colorScheme==="dark"?8:0,a,!1),e.colorScheme==="dark"?.2:1)};const u=r(),c=s.isSplittedColor?s.shade:u,f=s.isSplittedColor?s.key:i;return{border:"transparent",background:t(f,c,a),color:e.white,hover:t(f,c===9?8:c+1)}}}function Z$(e){return t=>{const r=Mi(e)(t);return e.colors[e.primaryColor][r]}}function J$(e){return{"@media (hover: hover)":{"&:hover":e},"@media (hover: none)":{"&:active":e}}}const $e={fontStyles:j$,themeColor:Nd,focusStyles:L$,linearGradient:F$,radialGradient:A$,smallerThan:H$,largerThan:V$,rgba:Pn,size:zd,cover:G$,darken:Y$,lighten:X$,radius:q$,variant:Q$,primaryShade:Mi,hover:J$,gradient:S1,primaryColor:Z$};var eO=Object.defineProperty,tO=Object.defineProperties,rO=Object.getOwnPropertyDescriptors,Mg=Object.getOwnPropertySymbols,nO=Object.prototype.hasOwnProperty,oO=Object.prototype.propertyIsEnumerable,jg=(e,t,r)=>t in e?eO(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,iO=(e,t)=>{for(var r in t||(t={}))nO.call(t,r)&&jg(e,r,t[r]);if(Mg)for(var r of Mg(t))oO.call(t,r)&&jg(e,r,t[r]);return e},lO=(e,t)=>tO(e,rO(t));function b1(e){return lO(iO({},e),{fn:{fontStyles:$e.fontStyles(e),themeColor:$e.themeColor(e),focusStyles:$e.focusStyles(e),largerThan:$e.largerThan(e),smallerThan:$e.smallerThan(e),radialGradient:$e.radialGradient,linearGradient:$e.linearGradient,gradient:$e.gradient(e),rgba:$e.rgba,size:$e.size,cover:$e.cover,lighten:$e.lighten,darken:$e.darken,primaryShade:$e.primaryShade(e),radius:$e.radius(e),variant:$e.variant(e),hover:$e.hover,primaryColor:$e.primaryColor(e)}})}Object.keys(w1);const aO=["xs","sm","md","lg","xl"],sO={dir:"ltr",primaryShade:{light:6,dark:8},focusRing:"auto",loader:"oval",dateFormat:"MMMM D, YYYY",colorScheme:"light",white:"#fff",black:"#000",defaultRadius:"sm",transitionTimingFunction:"ease",colors:w1,lineHeight:1.55,fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji",fontFamilyMonospace:"ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, Liberation Mono, Courier New, monospace",primaryColor:"blue",respectReducedMotion:!0,cursorType:"default",defaultGradient:{from:"indigo",to:"cyan",deg:45},shadows:{xs:"0 1px 3px rgba(0, 0, 0, 0.05), 0 1px 2px rgba(0, 0, 0, 0.1)",sm:"0 1px 3px rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0px 10px 15px -5px, rgba(0, 0, 0, 0.04) 0px 7px 7px -5px",md:"0 1px 3px rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0px 20px 25px -5px, rgba(0, 0, 0, 0.04) 0px 10px 10px -5px",lg:"0 1px 3px rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0px 28px 23px -7px, rgba(0, 0, 0, 0.04) 0px 12px 12px -7px",xl:"0 1px 3px rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.05) 0px 36px 28px -7px, rgba(0, 0, 0, 0.04) 0px 17px 17px -7px"},fontSizes:{xs:12,sm:14,md:16,lg:18,xl:20},radius:{xs:2,sm:4,md:8,lg:16,xl:32},spacing:{xs:10,sm:12,md:16,lg:20,xl:24},breakpoints:{xs:576,sm:768,md:992,lg:1200,xl:1400},headings:{fontFamily:"-apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica, Arial, sans-serif, Apple Color Emoji, Segoe UI Emoji",fontWeight:700,sizes:{h1:{fontSize:34,lineHeight:1.3,fontWeight:void 0},h2:{fontSize:26,lineHeight:1.35,fontWeight:void 0},h3:{fontSize:22,lineHeight:1.4,fontWeight:void 0},h4:{fontSize:18,lineHeight:1.45,fontWeight:void 0},h5:{fontSize:16,lineHeight:1.5,fontWeight:void 0},h6:{fontSize:14,lineHeight:1.5,fontWeight:void 0}}},other:{},components:{},activeStyles:{transform:"translateY(1px)"},datesLocale:"en"},Td=b1(sO);function uO(e){if(e.sheet)return e.sheet;for(var t=0;t0?Ge(oo,--qe):0,Yn--,we===10&&(Yn=1,Us--),we}function rt(){return we=qe2||xi(we)>3?"":" "}function SO(e,t){for(;--t&&rt()&&!(we<48||we>102||we>57&&we<65||we>70&&we<97););return ji(e,jl()+(t<6&&zt()==32&&rt()==32))}function cf(e){for(;rt();)switch(we){case e:return qe;case 34:case 39:e!==34&&e!==39&&cf(we);break;case 40:e===41&&cf(e);break;case 92:rt();break}return qe}function bO(e,t){for(;rt()&&e+we!==47+10;)if(e+we===42+42&&zt()===47)break;return"/*"+ji(t,qe-1)+"*"+Ws(e===47?e:rt())}function xO(e){for(;!xi(zt());)rt();return ji(e,qe)}function PO(e){return E1(Fl("",null,null,null,[""],e=C1(e),0,[0],e))}function Fl(e,t,r,n,o,i,l,a,s){for(var u=0,c=0,f=l,d=0,p=0,y=0,w=1,v=1,m=1,h=0,_="",b=o,O=i,x=n,P=_;v;)switch(y=h,h=rt()){case 40:if(y!=108&&P.charCodeAt(f-1)==58){uf(P+=oe(Ll(h),"&","&\f"),"&\f")!=-1&&(m=-1);break}case 34:case 39:case 91:P+=Ll(h);break;case 9:case 10:case 13:case 32:P+=_O(y);break;case 92:P+=SO(jl()-1,7);continue;case 47:switch(zt()){case 42:case 47:ul($O(bO(rt(),jl()),t,r),s);break;default:P+="/"}break;case 123*w:a[u++]=Ot(P)*m;case 125*w:case 59:case 0:switch(h){case 0:case 125:v=0;case 59+c:p>0&&Ot(P)-f&&ul(p>32?Fg(P+";",n,r,f-1):Fg(oe(P," ","")+";",n,r,f-2),s);break;case 59:P+=";";default:if(ul(x=Lg(P,t,r,u,c,o,a,_,b=[],O=[],f),i),h===123)if(c===0)Fl(P,t,x,x,b,i,f,a,O);else switch(d){case 100:case 109:case 115:Fl(e,x,x,n&&ul(Lg(e,x,x,0,0,o,a,_,o,b=[],f),O),o,O,f,a,n?b:O);break;default:Fl(P,x,x,x,[""],O,0,a,O)}}u=c=p=0,w=m=1,_=P="",f=l;break;case 58:f=1+Ot(P),p=y;default:if(w<1){if(h==123)--w;else if(h==125&&w++==0&&wO()==125)continue}switch(P+=Ws(h),h*w){case 38:m=c>0?1:(P+="\f",-1);break;case 44:a[u++]=(Ot(P)-1)*m,m=1;break;case 64:zt()===45&&(P+=Ll(rt())),d=zt(),c=f=Ot(_=P+=xO(jl())),h++;break;case 45:y===45&&Ot(P)==2&&(w=0)}}return i}function Lg(e,t,r,n,o,i,l,a,s,u,c){for(var f=o-1,d=o===0?i:[""],p=Ld(d),y=0,w=0,v=0;y0?d[m]+" "+h:oe(h,/&\f/g,d[m])))&&(s[v++]=_);return Gs(e,t,r,o===0?Md:a,s,u,c)}function $O(e,t,r){return Gs(e,t,r,x1,Ws(yO()),bi(e,2,-2),0)}function Fg(e,t,r,n){return Gs(e,t,r,jd,bi(e,0,n),bi(e,n+1,-1),n)}function k1(e,t){switch(mO(e,t)){case 5103:return te+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return te+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return te+e+pa+e+Te+e+e;case 6828:case 4268:return te+e+Te+e+e;case 6165:return te+e+Te+"flex-"+e+e;case 5187:return te+e+oe(e,/(\w+).+(:[^]+)/,te+"box-$1$2"+Te+"flex-$1$2")+e;case 5443:return te+e+Te+"flex-item-"+oe(e,/flex-|-self/,"")+e;case 4675:return te+e+Te+"flex-line-pack"+oe(e,/align-content|flex-|-self/,"")+e;case 5548:return te+e+Te+oe(e,"shrink","negative")+e;case 5292:return te+e+Te+oe(e,"basis","preferred-size")+e;case 6060:return te+"box-"+oe(e,"-grow","")+te+e+Te+oe(e,"grow","positive")+e;case 4554:return te+oe(e,/([^-])(transform)/g,"$1"+te+"$2")+e;case 6187:return oe(oe(oe(e,/(zoom-|grab)/,te+"$1"),/(image-set)/,te+"$1"),e,"")+e;case 5495:case 3959:return oe(e,/(image-set\([^]*)/,te+"$1$`$1");case 4968:return oe(oe(e,/(.+:)(flex-)?(.*)/,te+"box-pack:$3"+Te+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+te+e+e;case 4095:case 3583:case 4068:case 2532:return oe(e,/(.+)-inline(.+)/,te+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(Ot(e)-1-t>6)switch(Ge(e,t+1)){case 109:if(Ge(e,t+4)!==45)break;case 102:return oe(e,/(.+:)(.+)-([^]+)/,"$1"+te+"$2-$3$1"+pa+(Ge(e,t+3)==108?"$3":"$2-$3"))+e;case 115:return~uf(e,"stretch")?k1(oe(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(Ge(e,t+1)!==115)break;case 6444:switch(Ge(e,Ot(e)-3-(~uf(e,"!important")&&10))){case 107:return oe(e,":",":"+te)+e;case 101:return oe(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+te+(Ge(e,14)===45?"inline-":"")+"box$3$1"+te+"$2$3$1"+Te+"$2box$3")+e}break;case 5936:switch(Ge(e,t+11)){case 114:return te+e+Te+oe(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return te+e+Te+oe(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return te+e+Te+oe(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return te+e+Te+e+e}return e}function Hn(e,t){for(var r="",n=Ld(e),o=0;o-1&&!e.return)switch(e.type){case jd:e.return=k1(e.value,e.length);break;case P1:return Hn([Io(e,{value:oe(e.value,"@","@"+te)})],n);case Md:if(e.length)return hO(e.props,function(o){switch(vO(o,/(::plac\w+|:read-\w+)/)){case":read-only":case":read-write":return Hn([Io(e,{props:[oe(o,/:(read-\w+)/,":"+pa+"$1")]})],n);case"::placeholder":return Hn([Io(e,{props:[oe(o,/:(plac\w+)/,":"+te+"input-$1")]}),Io(e,{props:[oe(o,/:(plac\w+)/,":"+pa+"$1")]}),Io(e,{props:[oe(o,/:(plac\w+)/,Te+"input-$1")]})],n)}return""})}}function RO(e){var t=Object.create(null);return function(r){return t[r]===void 0&&(t[r]=e(r)),t[r]}}var IO=function(t,r,n){for(var o=0,i=0;o=i,i=zt(),o===38&&i===12&&(r[n]=1),!xi(i);)rt();return ji(t,qe)},NO=function(t,r){var n=-1,o=44;do switch(xi(o)){case 0:o===38&&zt()===12&&(r[n]=1),t[n]+=IO(qe-1,r,n);break;case 2:t[n]+=Ll(o);break;case 4:if(o===44){t[++n]=zt()===58?"&\f":"",r[n]=t[n].length;break}default:t[n]+=Ws(o)}while(o=rt());return t},zO=function(t,r){return E1(NO(C1(t),r))},Ag=new WeakMap,DO=function(t){if(!(t.type!=="rule"||!t.parent||t.length<1)){for(var r=t.value,n=t.parent,o=t.column===n.column&&t.line===n.line;n.type!=="rule";)if(n=n.parent,!n)return;if(!(t.props.length===1&&r.charCodeAt(0)!==58&&!Ag.get(n))&&!o){Ag.set(t,!0);for(var i=[],l=zO(r,i),a=n.props,s=0,u=0;s=4;++n,o-=4)r=e.charCodeAt(n)&255|(e.charCodeAt(++n)&255)<<8|(e.charCodeAt(++n)&255)<<16|(e.charCodeAt(++n)&255)<<24,r=(r&65535)*1540483477+((r>>>16)*59797<<16),r^=r>>>24,t=(r&65535)*1540483477+((r>>>16)*59797<<16)^(t&65535)*1540483477+((t>>>16)*59797<<16);switch(o){case 3:t^=(e.charCodeAt(n+2)&255)<<16;case 2:t^=(e.charCodeAt(n+1)&255)<<8;case 1:t^=e.charCodeAt(n)&255,t=(t&65535)*1540483477+((t>>>16)*59797<<16)}return t^=t>>>13,t=(t&65535)*1540483477+((t>>>16)*59797<<16),((t^t>>>15)>>>0).toString(36)}var qO={animationIterationCount:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1},KO=/[A-Z]|^ms/g,QO=/_EMO_([^_]+?)_([^]*?)_EMO_/g,M1=function(t){return t.charCodeAt(1)===45},Vg=function(t){return t!=null&&typeof t!="boolean"},qu=RO(function(e){return M1(e)?e:e.replace(KO,"-$&").toLowerCase()}),Hg=function(t,r){switch(t){case"animation":case"animationName":if(typeof r=="string")return r.replace(QO,function(n,o,i){return Ct={name:o,styles:i,next:Ct},o})}return qO[t]!==1&&!M1(t)&&typeof r=="number"&&r!==0?r+"px":r};function Pi(e,t,r){if(r==null)return"";if(r.__emotion_styles!==void 0)return r;switch(typeof r){case"boolean":return"";case"object":{if(r.anim===1)return Ct={name:r.name,styles:r.styles,next:Ct},r.name;if(r.styles!==void 0){var n=r.next;if(n!==void 0)for(;n!==void 0;)Ct={name:n.name,styles:n.styles,next:Ct},n=n.next;var o=r.styles+";";return o}return ZO(e,t,r)}case"function":{if(e!==void 0){var i=Ct,l=r(e);return Ct=i,Pi(e,t,l)}break}}if(t==null)return r;var a=t[r];return a!==void 0?a:r}function ZO(e,t,r){var n="";if(Array.isArray(r))for(var o=0;ot in e?tC(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,lC=(e,t)=>{for(var r in t||(t={}))oC.call(t,r)&&Gg(e,r,t[r]);if(Ug)for(var r of Ug(t))iC.call(t,r)&&Gg(e,r,t[r]);return e},aC=(e,t)=>rC(e,nC(t));function sC({theme:e}){return E.createElement(Hd,{styles:{"*, *::before, *::after":{boxSizing:"border-box"},body:aC(lC({},e.fn.fontStyles()),{backgroundColor:e.colorScheme==="dark"?e.colors.dark[7]:e.white,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,lineHeight:e.lineHeight,fontSize:e.fontSizes.md,WebkitFontSmoothing:"antialiased",MozOsxFontSmoothing:"grayscale"})}})}function cl(e,t,r){Object.keys(t).forEach(n=>{e[`--mantine-${r}-${n}`]=typeof t[n]=="number"?`${t[n]}px`:t[n]})}function uC({theme:e}){const t={"--mantine-color-white":e.white,"--mantine-color-black":e.black,"--mantine-transition-timing-function":e.transitionTimingFunction,"--mantine-line-height":`${e.lineHeight}`,"--mantine-font-family":e.fontFamily,"--mantine-font-family-monospace":e.fontFamilyMonospace,"--mantine-font-family-headings":e.headings.fontFamily,"--mantine-heading-font-weight":`${e.headings.fontWeight}`};cl(t,e.shadows,"shadow"),cl(t,e.fontSizes,"font-size"),cl(t,e.radius,"radius"),cl(t,e.spacing,"spacing"),Object.keys(e.colors).forEach(n=>{e.colors[n].forEach((o,i)=>{t[`--mantine-color-${n}-${i}`]=o})});const r=e.headings.sizes;return Object.keys(r).forEach(n=>{t[`--mantine-${n}-font-size`]=`${r[n].fontSize}px`,t[`--mantine-${n}-line-height`]=`${r[n].lineHeight}`}),E.createElement(Hd,{styles:{":root":t}})}var cC=Object.defineProperty,fC=Object.defineProperties,dC=Object.getOwnPropertyDescriptors,Yg=Object.getOwnPropertySymbols,pC=Object.prototype.hasOwnProperty,gC=Object.prototype.propertyIsEnumerable,Xg=(e,t,r)=>t in e?cC(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Lr=(e,t)=>{for(var r in t||(t={}))pC.call(t,r)&&Xg(e,r,t[r]);if(Yg)for(var r of Yg(t))gC.call(t,r)&&Xg(e,r,t[r]);return e},qg=(e,t)=>fC(e,dC(t));function mC(e,t){return t?Object.keys(e).reduce((r,n)=>{if(n==="headings"&&t.headings){const o=t.headings.sizes?Object.keys(e.headings.sizes).reduce((i,l)=>(i[l]=Lr(Lr({},e.headings.sizes[l]),t.headings.sizes[l]),i),{}):e.headings.sizes;return qg(Lr({},r),{headings:qg(Lr(Lr({},e.headings),t.headings),{sizes:o})})}return r[n]=typeof t[n]=="object"?Lr(Lr({},e[n]),t[n]):typeof t[n]=="number"||typeof t[n]=="boolean"?t[n]:t[n]||e[n],r},{}):e}function vC(e,t){return b1(mC(e,t))}function hC(e){return Object.keys(e).reduce((t,r)=>(e[r]!==void 0&&(t[r]=e[r]),t),{})}const yC={html:{fontFamily:"sans-serif",lineHeight:"1.15",textSizeAdjust:"100%"},body:{margin:0},"article, aside, footer, header, nav, section, figcaption, figure, main":{display:"block"},h1:{fontSize:"2em"},hr:{boxSizing:"content-box",height:0,overflow:"visible"},pre:{fontFamily:"monospace, monospace",fontSize:"1em"},a:{background:"transparent",textDecorationSkip:"objects"},"a:active, a:hover":{outlineWidth:0},"abbr[title]":{borderBottom:"none",textDecoration:"underline"},"b, strong":{fontWeight:"bolder"},"code, kbp, samp":{fontFamily:"monospace, monospace",fontSize:"1em"},dfn:{fontStyle:"italic"},mark:{backgroundColor:"#ff0",color:"#000"},small:{fontSize:"80%"},"sub, sup":{fontSize:"75%",lineHeight:0,position:"relative",verticalAlign:"baseline"},sup:{top:"-0.5em"},sub:{bottom:"-0.25em"},"audio, video":{display:"inline-block"},"audio:not([controls])":{display:"none",height:0},img:{borderStyle:"none",verticalAlign:"middle"},"svg:not(:root)":{overflow:"hidden"},"button, input, optgroup, select, textarea":{fontFamily:"sans-serif",fontSize:"100%",lineHeight:"1.15",margin:0},"button, input":{overflow:"visible"},"button, select":{textTransform:"none"},"button, [type=reset], [type=submit]":{WebkitAppearance:"button"},"button::-moz-focus-inner, [type=button]::-moz-focus-inner, [type=reset]::-moz-focus-inner, [type=submit]::-moz-focus-inner":{borderStyle:"none",padding:0},"button:-moz-focusring, [type=button]:-moz-focusring, [type=reset]:-moz-focusring, [type=submit]:-moz-focusring":{outline:"1px dotted ButtonText"},legend:{boxSizing:"border-box",color:"inherit",display:"table",maxWidth:"100%",padding:0,whiteSpace:"normal"},progress:{display:"inline-block",verticalAlign:"baseline"},textarea:{overflow:"auto"},"[type=checkbox], [type=radio]":{boxSizing:"border-box",padding:0},"[type=number]::-webkit-inner-spin-button, [type=number]::-webkit-outer-spin-button":{height:"auto"},"[type=search]":{appearance:"none"},"[type=search]::-webkit-search-cancel-button, [type=search]::-webkit-search-decoration":{appearance:"none"},"::-webkit-file-upload-button":{appearance:"button",font:"inherit"},"details, menu":{display:"block"},summary:{display:"list-item"},canvas:{display:"inline-block"},template:{display:"none"},"[hidden]":{display:"none"}};function wC(){return E.createElement(Hd,{styles:yC})}var _C=Object.defineProperty,Kg=Object.getOwnPropertySymbols,SC=Object.prototype.hasOwnProperty,bC=Object.prototype.propertyIsEnumerable,Qg=(e,t,r)=>t in e?_C(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,ni=(e,t)=>{for(var r in t||(t={}))SC.call(t,r)&&Qg(e,r,t[r]);if(Kg)for(var r of Kg(t))bC.call(t,r)&&Qg(e,r,t[r]);return e};const ga=g.exports.createContext({theme:Td});function at(){var e;return((e=g.exports.useContext(ga))==null?void 0:e.theme)||Td}function xC(e){const t=at(),r=n=>{var o,i;return{styles:((o=t.components[n])==null?void 0:o.styles)||{},classNames:((i=t.components[n])==null?void 0:i.classNames)||{}}};return Array.isArray(e)?e.map(r):[r(e)]}function PC(){var e;return(e=g.exports.useContext(ga))==null?void 0:e.emotionCache}function ee(e,t,r){var n;const i=(n=at().components[e])==null?void 0:n.defaultProps;return ni(ni(ni({},t),i),hC(r))}function F1({theme:e,emotionCache:t,withNormalizeCSS:r=!1,withGlobalStyles:n=!1,withCSSVariables:o=!1,inherit:i=!1,children:l}){const a=g.exports.useContext(ga),s=vC(Td,i?ni(ni({},a.theme),e):e);return U(ga.Provider,{value:{theme:s,emotionCache:t},children:[r&&S(wC,{}),n&&S(sC,{theme:s}),o&&S(uC,{theme:s}),l]})}F1.displayName="@mantine/core/MantineProvider";const A1=g.exports.createContext({classNames:{},styles:{},unstyled:!1});function V1({children:e,classNames:t,unstyled:r,styles:n,staticSelector:o}){return S(A1.Provider,{value:{classNames:t,styles:n,unstyled:r,staticSelector:o},children:e})}function dn(){return g.exports.useContext(A1)}const $C={app:100,modal:200,popover:300,overlay:400,max:9999};function io(e){return $C[e]}var Zg=Object.getOwnPropertySymbols,OC=Object.prototype.hasOwnProperty,CC=Object.prototype.propertyIsEnumerable,EC=(e,t)=>{var r={};for(var n in e)OC.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Zg)for(var n of Zg(e))t.indexOf(n)<0&&CC.call(e,n)&&(r[n]=e[n]);return r};function nu(e){const t=e,{m:r,mx:n,my:o,mt:i,mb:l,ml:a,mr:s,p:u,px:c,py:f,pt:d,pb:p,pl:y,pr:w}=t,v=EC(t,["m","mx","my","mt","mb","ml","mr","p","px","py","pt","pb","pl","pr"]),m={m:r,mx:n,my:o,mt:i,mb:l,ml:a,mr:s,p:u,px:c,py:f,pt:d,pb:p,pl:y,pr:w};return Object.keys(m).forEach(h=>{m[h]===void 0&&delete m[h]}),{systemStyles:m,rest:v}}function kC(e,t){const r=g.exports.useRef();return(!r.current||t.length!==r.current.prevDeps.length||r.current.prevDeps.map((n,o)=>n===t[o]).indexOf(!1)>=0)&&(r.current={v:e(),prevDeps:[...t]}),r.current.v}const RC=R1({key:"mantine",prepend:!0});function IC(){return PC()||RC}var NC=Object.defineProperty,Jg=Object.getOwnPropertySymbols,zC=Object.prototype.hasOwnProperty,DC=Object.prototype.propertyIsEnumerable,em=(e,t,r)=>t in e?NC(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,TC=(e,t)=>{for(var r in t||(t={}))zC.call(t,r)&&em(e,r,t[r]);if(Jg)for(var r of Jg(t))DC.call(t,r)&&em(e,r,t[r]);return e};const Ku="ref";function MC(e){let t;if(e.length!==1)return{args:e,ref:t};const[r]=e;if(!(r instanceof Object))return{args:e,ref:t};if(!(Ku in r))return{args:e,ref:t};t=r[Ku];const n=TC({},r);return delete n[Ku],{args:[n],ref:t}}const{cssFactory:jC}=(()=>{function e(r,n,o){const i=[],l=GO(r,i,o);return i.length<2?o:l+n(i)}function t(r){const{cache:n}=r,o=(...l)=>{const{ref:a,args:s}=MC(l),u=j1(s,n.registered);return T1(n,u,!1),`${n.key}-${u.name}${a===void 0?"":` ${a}`}`};return{css:o,cx:(...l)=>e(n.registered,o,y1(l))}}return{cssFactory:t}})();function H1(){const e=IC();return kC(()=>jC({cache:e}),[e])}function LC({cx:e,classes:t,context:r,classNames:n,name:o}){const i=r.reduce((l,a)=>(Object.keys(a.classNames).forEach(s=>{typeof l[s]!="string"?l[s]=`${a.classNames[s]}`:l[s]=`${l[s]} ${a.classNames[s]}`}),l),{});return Object.keys(t).reduce((l,a)=>(l[a]=e(t[a],i[a],n!=null&&n[a],Array.isArray(o)?o.filter(Boolean).map(s=>`mantine-${s}-${a}`).join(" "):o?`mantine-${o}-${a}`:null),l),{})}var FC=Object.defineProperty,tm=Object.getOwnPropertySymbols,AC=Object.prototype.hasOwnProperty,VC=Object.prototype.propertyIsEnumerable,rm=(e,t,r)=>t in e?FC(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Qu=(e,t)=>{for(var r in t||(t={}))AC.call(t,r)&&rm(e,r,t[r]);if(tm)for(var r of tm(t))VC.call(t,r)&&rm(e,r,t[r]);return e};function HC(e){return`__mantine-ref-${e||""}`}function nm(e,t,r){const n=o=>typeof o=="function"?o(t,r||{}):o||{};return Array.isArray(e)?e.map(o=>n(o.styles)).reduce((o,i)=>(Object.keys(i).forEach(l=>{o[l]?o[l]=Qu(Qu({},o[l]),i[l]):o[l]=Qu({},i[l])}),o),{}):n(e)}function Q(e){const t=typeof e=="function"?e:()=>e;function r(n,o){const i=at(),l=xC(o?.name),{css:a,cx:s}=H1(),u=t(i,n,HC),c=nm(o?.styles,i,n),f=nm(l,i,n),d=Object.fromEntries(Object.keys(u).map(p=>{const y=s({[a(u[p])]:!o?.unstyled},a(f[p]),a(c[p]));return[p,y]}));return{classes:LC({cx:s,classes:d,context:l,classNames:o?.classNames,name:o?.name}),cx:s,theme:i}}return r}var BC=Object.defineProperty,WC=Object.defineProperties,UC=Object.getOwnPropertyDescriptors,om=Object.getOwnPropertySymbols,GC=Object.prototype.hasOwnProperty,YC=Object.prototype.propertyIsEnumerable,im=(e,t,r)=>t in e?BC(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,No=(e,t)=>{for(var r in t||(t={}))GC.call(t,r)&&im(e,r,t[r]);if(om)for(var r of om(t))YC.call(t,r)&&im(e,r,t[r]);return e},zo=(e,t)=>WC(e,UC(t));const Do={in:{opacity:1,transform:"scale(1)"},out:{opacity:0,transform:"scale(.9) translateY(10px)"},transitionProperty:"transform, opacity"},fl={fade:{in:{opacity:1},out:{opacity:0},transitionProperty:"opacity"},scale:{in:{opacity:1,transform:"scale(1)"},out:{opacity:0,transform:"scale(0)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"scale-y":{in:{opacity:1,transform:"scaleY(1)"},out:{opacity:0,transform:"scaleY(0)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"scale-x":{in:{opacity:1,transform:"scaleX(1)"},out:{opacity:0,transform:"scaleX(0)"},common:{transformOrigin:"left"},transitionProperty:"transform, opacity"},"skew-up":{in:{opacity:1,transform:"translateY(0) skew(0deg, 0deg)"},out:{opacity:0,transform:"translateY(-20px) skew(-10deg, -5deg)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"skew-down":{in:{opacity:1,transform:"translateY(0) skew(0deg, 0deg)"},out:{opacity:0,transform:"translateY(20px) skew(-10deg, -5deg)"},common:{transformOrigin:"bottom"},transitionProperty:"transform, opacity"},"rotate-left":{in:{opacity:1,transform:"translateY(0) rotate(0deg)"},out:{opacity:0,transform:"translateY(20px) rotate(-5deg)"},common:{transformOrigin:"bottom"},transitionProperty:"transform, opacity"},"rotate-right":{in:{opacity:1,transform:"translateY(0) rotate(0deg)"},out:{opacity:0,transform:"translateY(20px) rotate(5deg)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"slide-down":{in:{opacity:1,transform:"translateY(0)"},out:{opacity:0,transform:"translateY(-100%)"},common:{transformOrigin:"top"},transitionProperty:"transform, opacity"},"slide-up":{in:{opacity:1,transform:"translateY(0)"},out:{opacity:0,transform:"translateY(100%)"},common:{transformOrigin:"bottom"},transitionProperty:"transform, opacity"},"slide-left":{in:{opacity:1,transform:"translateX(0)"},out:{opacity:0,transform:"translateX(100%)"},common:{transformOrigin:"left"},transitionProperty:"transform, opacity"},"slide-right":{in:{opacity:1,transform:"translateX(0)"},out:{opacity:0,transform:"translateX(-100%)"},common:{transformOrigin:"right"},transitionProperty:"transform, opacity"},pop:zo(No({},Do),{common:{transformOrigin:"center center"}}),"pop-bottom-left":zo(No({},Do),{common:{transformOrigin:"bottom left"}}),"pop-bottom-right":zo(No({},Do),{common:{transformOrigin:"bottom right"}}),"pop-top-left":zo(No({},Do),{common:{transformOrigin:"top left"}}),"pop-top-right":zo(No({},Do),{common:{transformOrigin:"top right"}})},lm=["mousedown","touchstart"];function XC(e,t,r){const n=g.exports.useRef();return g.exports.useEffect(()=>{const o=i=>{const{target:l}=i??{};if(Array.isArray(r)){const a=l?.hasAttribute("data-ignore-outside-clicks")||!document.body.contains(l);r.every(u=>!!u&&!u.contains(l))&&!a&&e()}else n.current&&!n.current.contains(l)&&e()};return(t||lm).forEach(i=>document.addEventListener(i,o)),()=>{(t||lm).forEach(i=>document.removeEventListener(i,o))}},[n,e,r]),n}function qC(e,t){try{return e.addEventListener("change",t),()=>e.removeEventListener("change",t)}catch{return e.addListener(t),()=>e.removeListener(t)}}function KC(e,t){return typeof t=="boolean"?t:typeof window<"u"&&"matchMedia"in window?window.matchMedia(e).matches:!1}function QC(e,t,{getInitialValueInEffect:r}={getInitialValueInEffect:!0}){const[n,o]=g.exports.useState(r?!1:KC(e,t)),i=g.exports.useRef();return g.exports.useEffect(()=>{if("matchMedia"in window)return i.current=window.matchMedia(e),o(i.current.matches),qC(i.current,l=>o(l.matches))},[e]),n}function Zu(e,t,r){return Math.min(Math.max(e,t),r)}const B1=typeof document<"u"?g.exports.useLayoutEffect:g.exports.useEffect;function kr(e,t){const r=g.exports.useRef(!1);g.exports.useEffect(()=>{r.current?e():r.current=!0},t)}function W1({opened:e,shouldReturnFocus:t=!0}){const r=g.exports.useRef(),n=()=>{var o;r.current&&"focus"in r.current&&typeof r.current.focus=="function"&&((o=r.current)==null||o.focus())};return kr(()=>{let o=-1;const i=l=>{l.key==="Tab"&&window.clearTimeout(o)};return document.addEventListener("keydown",i),e?r.current=document.activeElement:t&&(o=window.setTimeout(n,10)),()=>{window.clearTimeout(o),document.removeEventListener("keydown",i)}},[e]),n}const ZC=/input|select|textarea|button|object/,U1="a, input, select, textarea, button, object, [tabindex]";function JC(e){return e.style.display==="none"}function e2(e){if(e.getAttribute("aria-hidden")||e.getAttribute("hidden")||e.getAttribute("type")==="hidden")return!1;let r=e;for(;r&&r!==document.body;){if(JC(r))return!1;r=r.parentNode}return!0}function G1(e){let t=e.getAttribute("tabindex");return t===null&&(t=void 0),parseInt(t,10)}function ff(e){const t=e.nodeName.toLowerCase(),r=!Number.isNaN(G1(e));return(ZC.test(t)&&!e.disabled||e instanceof HTMLAnchorElement&&e.href||r)&&e2(e)}function Y1(e){const t=G1(e);return(Number.isNaN(t)||t>=0)&&ff(e)}function t2(e){return Array.from(e.querySelectorAll(U1)).filter(Y1)}function r2(e,t){const r=t2(e);if(!r.length){t.preventDefault();return}if(!(r[t.shiftKey?0:r.length-1]===document.activeElement||e===document.activeElement))return;t.preventDefault();const i=r[t.shiftKey?r.length-1:0];i&&i.focus()}function n2(e,t="body > :not(script)"){const r=Array.from(document.querySelectorAll(t)).map(n=>{if(n.contains(e))return;const o=n.getAttribute("aria-hidden");return(o===null||o==="false")&&n.setAttribute("aria-hidden","true"),{node:n,ariaHidden:o}});return()=>{r.forEach(n=>{!n||(n.ariaHidden===null?n.node.removeAttribute("aria-hidden"):n.node.setAttribute("aria-hidden",n.ariaHidden))})}}function X1(e=!0){const t=g.exports.useRef(),r=g.exports.useRef(null),n=g.exports.useCallback(o=>{if(!!e)if(r.current&&r.current(),o){const i=l=>{r.current=n2(l);let a=o.querySelector("[data-autofocus]");if(!a){const s=Array.from(o.querySelectorAll(U1));a=s.find(Y1)||s.find(ff)||null,!a&&ff(o)&&(a=o)}a&&a.focus()};setTimeout(()=>{o.ownerDocument&&i(o)}),t.current=o}else t.current=null},[e]);return g.exports.useEffect(()=>{if(!e)return;const o=i=>{i.key==="Tab"&&t.current&&r2(t.current,i)};return document.addEventListener("keydown",o),()=>{document.removeEventListener("keydown",o)}},[e]),n}const o2=()=>`mantine-${Math.random().toString(36).slice(2,11)}`,i2=E["useId".toString()]||(()=>{});function l2(){const[e,t]=g.exports.useState("");return B1(()=>{t(o2())},[]),e}function a2(){const e=i2();return e?`mantine-${e.replace(/:/g,"")}`:""}function lo(e){return typeof e=="string"?e:a2()||l2()}function am(e,t,r){g.exports.useEffect(()=>(window.addEventListener(e,t,r),()=>window.removeEventListener(e,t,r)),[])}function q1(e,t){typeof e=="function"?e(t):typeof e=="object"&&e!==null&&"current"in e&&(e.current=t)}function s2(...e){return t=>{e.forEach(r=>q1(r,t))}}function pn(...e){return g.exports.useCallback(s2(...e),e)}function Li({value:e,defaultValue:t,finalValue:r,onChange:n=()=>{}}){const[o,i]=g.exports.useState(t!==void 0?t:r),l=a=>{i(a),n?.(a)};return e!==void 0?[e,n,!0]:[o,l,!1]}function ir(e,t){const r=t-e+1;return Array.from({length:r},(n,o)=>o+e)}const dl="dots";function u2({total:e,siblings:t=1,boundaries:r=1,page:n,initialPage:o=1,onChange:i}){const[l,a]=Li({value:n,onChange:i,defaultValue:o,finalValue:o}),s=y=>{y<=0?a(1):y>e?a(e):a(y)},u=()=>s(l+1),c=()=>s(l-1),f=()=>s(1),d=()=>s(e);return{range:g.exports.useMemo(()=>{if(t*2+3+r*2>=e)return ir(1,e);const w=Math.max(l-t,r),v=Math.min(l+t,e-r),m=w>r+2,h=ve<.5?2*e*e:-1+(4-2*e)*e,f2=({axis:e,target:t,parent:r,alignment:n,offset:o,isList:i})=>{if(!t||!r&&typeof document>"u")return 0;const l=!!r,s=(r||document.body).getBoundingClientRect(),u=t.getBoundingClientRect(),c=f=>u[f]-s[f];if(e==="y"){const f=c("top");if(f===0)return 0;if(n==="start"){const p=f-o;return p<=u.height*(i?0:1)||!i?p:0}const d=l?s.height:window.innerHeight;if(n==="end"){const p=f+o-d+u.height;return p>=-u.height*(i?0:1)||!i?p:0}return n==="center"?f-d/2+u.height/2:0}if(e==="x"){const f=c("left");if(f===0)return 0;if(n==="start"){const p=f-o;return p<=u.width||!i?p:0}const d=l?s.width:window.innerWidth;if(n==="end"){const p=f+o-d+u.width;return p>=-u.width||!i?p:0}return n==="center"?f-d/2+u.width/2:0}return 0},d2=({axis:e,parent:t})=>{if(!t&&typeof document>"u")return 0;const r=e==="y"?"scrollTop":"scrollLeft";if(t)return t[r];const{body:n,documentElement:o}=document;return n[r]+o[r]},p2=({axis:e,parent:t,distance:r})=>{if(!t&&typeof document>"u")return;const n=e==="y"?"scrollTop":"scrollLeft";if(t)t[n]=r;else{const{body:o,documentElement:i}=document;o[n]=r,i[n]=r}};function g2({duration:e=1250,axis:t="y",onScrollFinish:r,easing:n=c2,offset:o=0,cancelable:i=!0,isList:l=!1}={}){const a=g.exports.useRef(0),s=g.exports.useRef(0),u=g.exports.useRef(!1),c=g.exports.useRef(null),f=g.exports.useRef(null),d=K1(),p=()=>{a.current&&cancelAnimationFrame(a.current)},y=g.exports.useCallback(({alignment:v="start"}={})=>{var m;u.current=!1,a.current&&p();const h=(m=d2({parent:c.current,axis:t}))!=null?m:0,_=f2({parent:c.current,target:f.current,axis:t,alignment:v,offset:o,isList:l})-(c.current?0:h);function b(){s.current===0&&(s.current=performance.now());const x=performance.now()-s.current,P=d||e===0?1:x/e,$=h+_*n(P);p2({parent:c.current,axis:t,distance:$}),!u.current&&P<1?a.current=requestAnimationFrame(b):(typeof r=="function"&&r(),s.current=0,a.current=0,p())}b()},[c.current]),w=()=>{i&&(u.current=!0)};return am("wheel",w,{passive:!0}),am("touchmove",w,{passive:!0}),g.exports.useEffect(()=>p,[]),{scrollableRef:c,targetRef:f,scrollIntoView:y,cancel:p}}function m2(){if(typeof window>"u"||typeof document>"u")return 0;const e=parseInt(window.getComputedStyle(document.body).paddingRight,10),t=window.innerWidth-document.documentElement.clientWidth;return e+t}const v2=({disableBodyPadding:e})=>{const t=e?null:m2();return`body { + --removed-scroll-width: ${t}px; + touch-action: none; + overflow: hidden !important; + position: relative !important; + ${t?"padding-right: var(--removed-scroll-width) !important;":""} + `};function h2(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function y2(e){(document.head||document.getElementsByTagName("head")[0]).appendChild(e)}function w2(){const e=document.createElement("style");return e.type="text/css",e.setAttribute("mantine-scroll-lock",""),e}function _2(e,t={disableBodyPadding:!1}){const[r,n]=g.exports.useState(e||!1),o=g.exports.useRef(0),{disableBodyPadding:i}=t,l=g.exports.useRef(null),a=()=>{o.current=window.scrollY;const u=v2({disableBodyPadding:i}),c=w2();h2(c,u),y2(c),l.current=c},s=()=>{!l?.current||(l.current.parentNode.removeChild(l.current),l.current=null)};return g.exports.useEffect(()=>(r?a():s(),s),[r]),g.exports.useEffect(()=>{e!==void 0&&n(e)},[e]),g.exports.useEffect(()=>{e===void 0&&typeof window<"u"&&window.document.body.style.overflow==="hidden"&&n(!0)},[n]),[r,n]}function S2(){const{userAgent:e}=window.navigator,t=/(Macintosh)|(MacIntel)|(MacPPC)|(Mac68K)/i,r=/(Win32)|(Win64)|(Windows)|(WinCE)/i,n=/(iPhone)|(iPad)|(iPod)/i;return t.test(e)?"macos":n.test(e)?"ios":r.test(e)?"windows":/Android/i.test(e)?"android":/Linux/i.test(e)?"linux":"undetermined"}function b2(){return typeof window<"u"?S2():"undetermined"}function Al(){return`mantine-${Math.random().toString(36).slice(2,11)}`}const sm={mt:"marginTop",mb:"marginBottom",ml:"marginLeft",mr:"marginRight",pt:"paddingTop",pb:"paddingBottom",pl:"paddingLeft",pr:"paddingRight"},x2=["-xs","-sm","-md","-lg","-xl"];function Fr(e){return typeof e=="string"||typeof e=="number"}function Ar(e,t){return x2.includes(e)?t.fn.size({size:e.replace("-",""),sizes:t.spacing})*-1:t.fn.size({size:e,sizes:t.spacing})}function um(e,t){const r={};if(Fr(e.p)){const n=Ar(e.p,t);r.padding=n}if(Fr(e.m)){const n=Ar(e.m,t);r.margin=n}if(Fr(e.py)){const n=Ar(e.py,t);r.paddingTop=n,r.paddingBottom=n}if(Fr(e.px)){const n=Ar(e.px,t);r.paddingLeft=n,r.paddingRight=n}if(Fr(e.my)){const n=Ar(e.my,t);r.marginTop=n,r.marginBottom=n}if(Fr(e.mx)){const n=Ar(e.mx,t);r.marginLeft=n,r.marginRight=n}return Object.keys(sm).forEach(n=>{Fr(e[n])&&(r[sm[n]]=t.fn.size({size:Ar(e[n],t),sizes:t.spacing}))}),r}function cm(e,t){return typeof e=="function"?e(t):e}function P2(e,t,r){const n=at(),{css:o,cx:i}=H1();return Array.isArray(e)?i(r,o(um(t,n)),e.map(l=>o(cm(l,n)))):i(r,o(cm(e,n)),o(um(t,n)))}var $2=Object.defineProperty,ma=Object.getOwnPropertySymbols,Q1=Object.prototype.hasOwnProperty,Z1=Object.prototype.propertyIsEnumerable,fm=(e,t,r)=>t in e?$2(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,O2=(e,t)=>{for(var r in t||(t={}))Q1.call(t,r)&&fm(e,r,t[r]);if(ma)for(var r of ma(t))Z1.call(t,r)&&fm(e,r,t[r]);return e},C2=(e,t)=>{var r={};for(var n in e)Q1.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&ma)for(var n of ma(e))t.indexOf(n)<0&&Z1.call(e,n)&&(r[n]=e[n]);return r};const J1=g.exports.forwardRef((e,t)=>{var r=e,{className:n,component:o,style:i,sx:l}=r,a=C2(r,["className","component","style","sx"]);const{systemStyles:s,rest:u}=nu(a);return S(o||"div",{...O2({ref:t,className:P2(l,s,n),style:i},u)})});J1.displayName="@mantine/core/Box";const q=J1;var E2=Object.defineProperty,k2=Object.defineProperties,R2=Object.getOwnPropertyDescriptors,dm=Object.getOwnPropertySymbols,I2=Object.prototype.hasOwnProperty,N2=Object.prototype.propertyIsEnumerable,pm=(e,t,r)=>t in e?E2(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,gm=(e,t)=>{for(var r in t||(t={}))I2.call(t,r)&&pm(e,r,t[r]);if(dm)for(var r of dm(t))N2.call(t,r)&&pm(e,r,t[r]);return e},z2=(e,t)=>k2(e,R2(t)),D2=Q(e=>({root:z2(gm(gm({},e.fn.focusStyles()),e.fn.fontStyles()),{cursor:"pointer",border:0,padding:0,appearance:"none",fontSize:e.fontSizes.md,backgroundColor:"transparent",textAlign:"left",color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,textDecoration:"none",boxSizing:"border-box"})})),T2=D2,M2=Object.defineProperty,va=Object.getOwnPropertySymbols,ew=Object.prototype.hasOwnProperty,tw=Object.prototype.propertyIsEnumerable,mm=(e,t,r)=>t in e?M2(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,j2=(e,t)=>{for(var r in t||(t={}))ew.call(t,r)&&mm(e,r,t[r]);if(va)for(var r of va(t))tw.call(t,r)&&mm(e,r,t[r]);return e},L2=(e,t)=>{var r={};for(var n in e)ew.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&va)for(var n of va(e))t.indexOf(n)<0&&tw.call(e,n)&&(r[n]=e[n]);return r};const rw=g.exports.forwardRef((e,t)=>{const r=ee("UnstyledButton",{},e),{className:n,component:o="button",unstyled:i}=r,l=L2(r,["className","component","unstyled"]),{classes:a,cx:s}=T2(null,{name:"UnstyledButton",unstyled:i});return S(q,{...j2({component:o,ref:t,className:s(a.root,n),type:o==="button"?"button":void 0},l)})});rw.displayName="@mantine/core/UnstyledButton";const ou=rw;var F2=Object.defineProperty,A2=Object.defineProperties,V2=Object.getOwnPropertyDescriptors,vm=Object.getOwnPropertySymbols,H2=Object.prototype.hasOwnProperty,B2=Object.prototype.propertyIsEnumerable,hm=(e,t,r)=>t in e?F2(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,nw=(e,t)=>{for(var r in t||(t={}))H2.call(t,r)&&hm(e,r,t[r]);if(vm)for(var r of vm(t))B2.call(t,r)&&hm(e,r,t[r]);return e},W2=(e,t)=>A2(e,V2(t));const Wo={xs:18,sm:22,md:28,lg:34,xl:44};function U2({variant:e,theme:t,color:r}){if(e==="transparent")return{border:"1px solid transparent",color:t.fn.variant({variant:"subtle",color:r}).color,backgroundColor:"transparent"};const n=t.fn.variant({color:r,variant:e});return nw({backgroundColor:n.background,color:n.color,border:`1px solid ${n.border}`},t.fn.hover({backgroundColor:n.hover}))}var G2=Q((e,{color:t,size:r,radius:n,variant:o})=>({root:W2(nw({},U2({variant:o,theme:e,color:t})),{position:"relative",height:e.fn.size({size:r,sizes:Wo}),minHeight:e.fn.size({size:r,sizes:Wo}),width:e.fn.size({size:r,sizes:Wo}),minWidth:e.fn.size({size:r,sizes:Wo}),borderRadius:e.fn.radius(n),padding:0,lineHeight:1,display:"flex",alignItems:"center",justifyContent:"center","&:active":e.activeStyles,"&[data-disabled]":{color:e.colors.gray[e.colorScheme==="dark"?6:4],cursor:"not-allowed",backgroundColor:o==="transparent"?void 0:e.fn.themeColor("gray",e.colorScheme==="dark"?8:1),borderColor:o==="transparent"?void 0:e.fn.themeColor("gray",e.colorScheme==="dark"?8:1),"&:active":{transform:"none"}},"&[data-loading]":{pointerEvents:"none","&::before":{content:'""',position:"absolute",top:-1,left:-1,right:-1,bottom:-1,backgroundColor:e.colorScheme==="dark"?e.fn.rgba(e.colors.dark[7],.5):"rgba(255, 255, 255, .5)",borderRadius:e.fn.radius(n),cursor:"not-allowed"}}})})),Y2=G2,X2=Object.defineProperty,ha=Object.getOwnPropertySymbols,ow=Object.prototype.hasOwnProperty,iw=Object.prototype.propertyIsEnumerable,ym=(e,t,r)=>t in e?X2(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,q2=(e,t)=>{for(var r in t||(t={}))ow.call(t,r)&&ym(e,r,t[r]);if(ha)for(var r of ha(t))iw.call(t,r)&&ym(e,r,t[r]);return e},K2=(e,t)=>{var r={};for(var n in e)ow.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&ha)for(var n of ha(e))t.indexOf(n)<0&&iw.call(e,n)&&(r[n]=e[n]);return r};function Q2(e){var t=e,{size:r,color:n}=t,o=K2(t,["size","color"]);return E.createElement("svg",q2({viewBox:"0 0 135 140",xmlns:"http://www.w3.org/2000/svg",fill:n,width:`${r}px`},o),E.createElement("rect",{y:"10",width:"15",height:"120",rx:"6"},E.createElement("animate",{attributeName:"height",begin:"0.5s",dur:"1s",values:"120;110;100;90;80;70;60;50;40;140;120",calcMode:"linear",repeatCount:"indefinite"}),E.createElement("animate",{attributeName:"y",begin:"0.5s",dur:"1s",values:"10;15;20;25;30;35;40;45;50;0;10",calcMode:"linear",repeatCount:"indefinite"})),E.createElement("rect",{x:"30",y:"10",width:"15",height:"120",rx:"6"},E.createElement("animate",{attributeName:"height",begin:"0.25s",dur:"1s",values:"120;110;100;90;80;70;60;50;40;140;120",calcMode:"linear",repeatCount:"indefinite"}),E.createElement("animate",{attributeName:"y",begin:"0.25s",dur:"1s",values:"10;15;20;25;30;35;40;45;50;0;10",calcMode:"linear",repeatCount:"indefinite"})),E.createElement("rect",{x:"60",width:"15",height:"140",rx:"6"},E.createElement("animate",{attributeName:"height",begin:"0s",dur:"1s",values:"120;110;100;90;80;70;60;50;40;140;120",calcMode:"linear",repeatCount:"indefinite"}),E.createElement("animate",{attributeName:"y",begin:"0s",dur:"1s",values:"10;15;20;25;30;35;40;45;50;0;10",calcMode:"linear",repeatCount:"indefinite"})),E.createElement("rect",{x:"90",y:"10",width:"15",height:"120",rx:"6"},E.createElement("animate",{attributeName:"height",begin:"0.25s",dur:"1s",values:"120;110;100;90;80;70;60;50;40;140;120",calcMode:"linear",repeatCount:"indefinite"}),E.createElement("animate",{attributeName:"y",begin:"0.25s",dur:"1s",values:"10;15;20;25;30;35;40;45;50;0;10",calcMode:"linear",repeatCount:"indefinite"})),E.createElement("rect",{x:"120",y:"10",width:"15",height:"120",rx:"6"},E.createElement("animate",{attributeName:"height",begin:"0.5s",dur:"1s",values:"120;110;100;90;80;70;60;50;40;140;120",calcMode:"linear",repeatCount:"indefinite"}),E.createElement("animate",{attributeName:"y",begin:"0.5s",dur:"1s",values:"10;15;20;25;30;35;40;45;50;0;10",calcMode:"linear",repeatCount:"indefinite"})))}var Z2=Object.defineProperty,ya=Object.getOwnPropertySymbols,lw=Object.prototype.hasOwnProperty,aw=Object.prototype.propertyIsEnumerable,wm=(e,t,r)=>t in e?Z2(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,J2=(e,t)=>{for(var r in t||(t={}))lw.call(t,r)&&wm(e,r,t[r]);if(ya)for(var r of ya(t))aw.call(t,r)&&wm(e,r,t[r]);return e},eE=(e,t)=>{var r={};for(var n in e)lw.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&ya)for(var n of ya(e))t.indexOf(n)<0&&aw.call(e,n)&&(r[n]=e[n]);return r};function tE(e){var t=e,{size:r,color:n}=t,o=eE(t,["size","color"]);return E.createElement("svg",J2({width:`${r}px`,height:`${r}px`,viewBox:"0 0 38 38",xmlns:"http://www.w3.org/2000/svg",stroke:n},o),E.createElement("g",{fill:"none",fillRule:"evenodd"},E.createElement("g",{transform:"translate(2.5 2.5)",strokeWidth:"5"},E.createElement("circle",{strokeOpacity:".5",cx:"16",cy:"16",r:"16"}),E.createElement("path",{d:"M32 16c0-9.94-8.06-16-16-16"},E.createElement("animateTransform",{attributeName:"transform",type:"rotate",from:"0 16 16",to:"360 16 16",dur:"1s",repeatCount:"indefinite"})))))}var rE=Object.defineProperty,wa=Object.getOwnPropertySymbols,sw=Object.prototype.hasOwnProperty,uw=Object.prototype.propertyIsEnumerable,_m=(e,t,r)=>t in e?rE(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,nE=(e,t)=>{for(var r in t||(t={}))sw.call(t,r)&&_m(e,r,t[r]);if(wa)for(var r of wa(t))uw.call(t,r)&&_m(e,r,t[r]);return e},oE=(e,t)=>{var r={};for(var n in e)sw.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&wa)for(var n of wa(e))t.indexOf(n)<0&&uw.call(e,n)&&(r[n]=e[n]);return r};function iE(e){var t=e,{size:r,color:n}=t,o=oE(t,["size","color"]);return E.createElement("svg",nE({width:`${r}px`,height:`${r/4}px`,viewBox:"0 0 120 30",xmlns:"http://www.w3.org/2000/svg",fill:n},o),E.createElement("circle",{cx:"15",cy:"15",r:"15"},E.createElement("animate",{attributeName:"r",from:"15",to:"15",begin:"0s",dur:"0.8s",values:"15;9;15",calcMode:"linear",repeatCount:"indefinite"}),E.createElement("animate",{attributeName:"fill-opacity",from:"1",to:"1",begin:"0s",dur:"0.8s",values:"1;.5;1",calcMode:"linear",repeatCount:"indefinite"})),E.createElement("circle",{cx:"60",cy:"15",r:"9",fillOpacity:"0.3"},E.createElement("animate",{attributeName:"r",from:"9",to:"9",begin:"0s",dur:"0.8s",values:"9;15;9",calcMode:"linear",repeatCount:"indefinite"}),E.createElement("animate",{attributeName:"fill-opacity",from:"0.5",to:"0.5",begin:"0s",dur:"0.8s",values:".5;1;.5",calcMode:"linear",repeatCount:"indefinite"})),E.createElement("circle",{cx:"105",cy:"15",r:"15"},E.createElement("animate",{attributeName:"r",from:"15",to:"15",begin:"0s",dur:"0.8s",values:"15;9;15",calcMode:"linear",repeatCount:"indefinite"}),E.createElement("animate",{attributeName:"fill-opacity",from:"1",to:"1",begin:"0s",dur:"0.8s",values:"1;.5;1",calcMode:"linear",repeatCount:"indefinite"})))}var lE=Object.defineProperty,_a=Object.getOwnPropertySymbols,cw=Object.prototype.hasOwnProperty,fw=Object.prototype.propertyIsEnumerable,Sm=(e,t,r)=>t in e?lE(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,aE=(e,t)=>{for(var r in t||(t={}))cw.call(t,r)&&Sm(e,r,t[r]);if(_a)for(var r of _a(t))fw.call(t,r)&&Sm(e,r,t[r]);return e},sE=(e,t)=>{var r={};for(var n in e)cw.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&_a)for(var n of _a(e))t.indexOf(n)<0&&fw.call(e,n)&&(r[n]=e[n]);return r};const Ju={bars:Q2,oval:tE,dots:iE},uE={xs:18,sm:22,md:36,lg:44,xl:58},cE={size:"md"};function Bd(e){const t=ee("Loader",cE,e),{size:r,color:n,variant:o}=t,i=sE(t,["size","color","variant"]),l=at(),a=o in Ju?o:l.loader;return E.createElement(q,aE({role:"presentation",component:Ju[a]||Ju.bars,size:l.fn.size({size:r,sizes:uE}),color:l.fn.variant({variant:"filled",primaryFallback:!1,color:n||l.primaryColor}).background},i))}Bd.displayName="@mantine/core/Loader";var fE=Object.defineProperty,Sa=Object.getOwnPropertySymbols,dw=Object.prototype.hasOwnProperty,pw=Object.prototype.propertyIsEnumerable,bm=(e,t,r)=>t in e?fE(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,xm=(e,t)=>{for(var r in t||(t={}))dw.call(t,r)&&bm(e,r,t[r]);if(Sa)for(var r of Sa(t))pw.call(t,r)&&bm(e,r,t[r]);return e},dE=(e,t)=>{var r={};for(var n in e)dw.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Sa)for(var n of Sa(e))t.indexOf(n)<0&&pw.call(e,n)&&(r[n]=e[n]);return r};const pE={color:"gray",size:"md",variant:"subtle",loading:!1},gw=g.exports.forwardRef((e,t)=>{const r=ee("ActionIcon",pE,e),{className:n,color:o,children:i,radius:l,size:a,variant:s,disabled:u,loaderProps:c,loading:f,unstyled:d}=r,p=dE(r,["className","color","children","radius","size","variant","disabled","loaderProps","loading","unstyled"]),{classes:y,cx:w,theme:v}=Y2({size:a,radius:l,color:o,variant:s},{name:"ActionIcon",unstyled:d}),m=v.fn.variant({color:o,variant:"light"}),h=S(Bd,{...xm({color:m.color,size:v.fn.size({size:a,sizes:Wo})-12},c)});return S(ou,{...xm({className:w(y.root,n),ref:t,disabled:u||f,"data-disabled":u||void 0,"data-loading":f||void 0,unstyled:d},p),children:f?h:i})});gw.displayName="@mantine/core/ActionIcon";const $t=gw;function mw(e){const{children:t,target:r,className:n}=ee("Portal",{},e),o=at(),[i,l]=g.exports.useState(!1),a=g.exports.useRef();return B1(()=>(l(!0),a.current=r?typeof r=="string"?document.querySelector(r):r:document.createElement("div"),r||document.body.appendChild(a.current),()=>{!r&&document.body.removeChild(a.current)}),[r]),i?Ei.exports.createPortal(S("div",{className:n,dir:o.dir,children:t}),a.current):null}mw.displayName="@mantine/core/Portal";var gE=Object.defineProperty,ba=Object.getOwnPropertySymbols,vw=Object.prototype.hasOwnProperty,hw=Object.prototype.propertyIsEnumerable,Pm=(e,t,r)=>t in e?gE(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,mE=(e,t)=>{for(var r in t||(t={}))vw.call(t,r)&&Pm(e,r,t[r]);if(ba)for(var r of ba(t))hw.call(t,r)&&Pm(e,r,t[r]);return e},vE=(e,t)=>{var r={};for(var n in e)vw.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&ba)for(var n of ba(e))t.indexOf(n)<0&&hw.call(e,n)&&(r[n]=e[n]);return r};function Fi(e){var t=e,{withinPortal:r=!0,children:n}=t,o=vE(t,["withinPortal","children"]);return r?E.createElement(mw,mE({},o),n):E.createElement(E.Fragment,null,n)}Fi.displayName="@mantine/core/OptionalPortal";var hE=Object.defineProperty,$m=Object.getOwnPropertySymbols,yE=Object.prototype.hasOwnProperty,wE=Object.prototype.propertyIsEnumerable,Om=(e,t,r)=>t in e?hE(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,_E=(e,t)=>{for(var r in t||(t={}))yE.call(t,r)&&Om(e,r,t[r]);if($m)for(var r of $m(t))wE.call(t,r)&&Om(e,r,t[r]);return e};function yw(e){return E.createElement("svg",_E({viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),E.createElement("path",{d:"M11.7816 4.03157C12.0062 3.80702 12.0062 3.44295 11.7816 3.2184C11.5571 2.99385 11.193 2.99385 10.9685 3.2184L7.50005 6.68682L4.03164 3.2184C3.80708 2.99385 3.44301 2.99385 3.21846 3.2184C2.99391 3.44295 2.99391 3.80702 3.21846 4.03157L6.68688 7.49999L3.21846 10.9684C2.99391 11.193 2.99391 11.557 3.21846 11.7816C3.44301 12.0061 3.80708 12.0061 4.03164 11.7816L7.50005 8.31316L10.9685 11.7816C11.193 12.0061 11.5571 12.0061 11.7816 11.7816C12.0062 11.557 12.0062 11.193 11.7816 10.9684L8.31322 7.49999L11.7816 4.03157Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}yw.displayName="@mantine/core/CloseIcon";var SE=Object.defineProperty,xa=Object.getOwnPropertySymbols,ww=Object.prototype.hasOwnProperty,_w=Object.prototype.propertyIsEnumerable,Cm=(e,t,r)=>t in e?SE(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,bE=(e,t)=>{for(var r in t||(t={}))ww.call(t,r)&&Cm(e,r,t[r]);if(xa)for(var r of xa(t))_w.call(t,r)&&Cm(e,r,t[r]);return e},xE=(e,t)=>{var r={};for(var n in e)ww.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&xa)for(var n of xa(e))t.indexOf(n)<0&&_w.call(e,n)&&(r[n]=e[n]);return r};const PE={xs:12,sm:14,md:16,lg:20,xl:24},$E={size:"md"},iu=g.exports.forwardRef((e,t)=>{const r=ee("CloseButton",$E,e),{iconSize:n,size:o="md"}=r,i=xE(r,["iconSize","size"]),l=at(),a=n||l.fn.size({size:o,sizes:PE});return S($t,{...bE({size:o,ref:t},i),children:S(yw,{width:a,height:a})})});iu.displayName="@mantine/core/CloseButton";var OE=Object.defineProperty,CE=Object.defineProperties,EE=Object.getOwnPropertyDescriptors,Em=Object.getOwnPropertySymbols,kE=Object.prototype.hasOwnProperty,RE=Object.prototype.propertyIsEnumerable,km=(e,t,r)=>t in e?OE(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,pl=(e,t)=>{for(var r in t||(t={}))kE.call(t,r)&&km(e,r,t[r]);if(Em)for(var r of Em(t))RE.call(t,r)&&km(e,r,t[r]);return e},IE=(e,t)=>CE(e,EE(t));function NE({underline:e,strikethrough:t}){const r=[];return e&&r.push("underline"),t&&r.push("line-through"),r.length>0?r.join(" "):"none"}function zE({theme:e,color:t,variant:r}){return t==="dimmed"?e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6]:typeof t=="string"&&(t in e.colors||t.split(".")[0]in e.colors)?e.fn.variant({variant:"filled",color:t}).background:r==="link"?e.colors[e.primaryColor][e.colorScheme==="dark"?4:7]:t||"inherit"}function DE(e){return typeof e=="number"?{overflow:"hidden",textOverflow:"ellipsis",display:"-webkit-box",WebkitLineClamp:e,WebkitBoxOrient:"vertical"}:null}var TE=Q((e,{color:t,variant:r,size:n,lineClamp:o,inline:i,inherit:l,underline:a,gradient:s,weight:u,transform:c,align:f,strikethrough:d,italic:p})=>{const y=e.fn.variant({variant:"gradient",gradient:s});return{root:pl(IE(pl(pl(pl({},e.fn.fontStyles()),e.fn.focusStyles()),DE(o)),{color:zE({color:t,theme:e,variant:r}),fontFamily:l?"inherit":e.fontFamily,fontSize:l||n===void 0?"inherit":e.fn.size({size:n,sizes:e.fontSizes}),lineHeight:l?"inherit":i?1:e.lineHeight,textDecoration:NE({underline:a,strikethrough:d}),WebkitTapHighlightColor:"transparent",fontWeight:l?"inherit":u,textTransform:c,textAlign:f,fontStyle:p?"italic":void 0}),e.fn.hover(r==="link"&&a===void 0?{textDecoration:"underline"}:void 0)),gradient:{backgroundImage:y.background,WebkitBackgroundClip:"text",WebkitTextFillColor:"transparent"}}}),ME=TE,jE=Object.defineProperty,Pa=Object.getOwnPropertySymbols,Sw=Object.prototype.hasOwnProperty,bw=Object.prototype.propertyIsEnumerable,Rm=(e,t,r)=>t in e?jE(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,LE=(e,t)=>{for(var r in t||(t={}))Sw.call(t,r)&&Rm(e,r,t[r]);if(Pa)for(var r of Pa(t))bw.call(t,r)&&Rm(e,r,t[r]);return e},FE=(e,t)=>{var r={};for(var n in e)Sw.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Pa)for(var n of Pa(e))t.indexOf(n)<0&&bw.call(e,n)&&(r[n]=e[n]);return r};const AE={variant:"text"},xw=g.exports.forwardRef((e,t)=>{const r=ee("Text",AE,e),{className:n,size:o,weight:i,transform:l,color:a,align:s,variant:u,lineClamp:c,gradient:f,inline:d,inherit:p,underline:y,strikethrough:w,italic:v,classNames:m,styles:h,unstyled:_,span:b}=r,O=FE(r,["className","size","weight","transform","color","align","variant","lineClamp","gradient","inline","inherit","underline","strikethrough","italic","classNames","styles","unstyled","span"]),{classes:x,cx:P}=ME({variant:u,color:a,size:o,lineClamp:c,inline:d,inherit:p,underline:y,strikethrough:w,italic:v,weight:i,transform:l,align:s,gradient:f},{unstyled:_,name:"Text"});return S(q,{...LE({ref:t,className:P(x.root,{[x.gradient]:u==="gradient"},n),component:b?"span":"div"},O)})});xw.displayName="@mantine/core/Text";const mt=xw,gl={xs:1,sm:2,md:3,lg:4,xl:5};function ml(e,t){const r=e.fn.variant({variant:"outline",color:t}).border;return typeof t=="string"&&(t in e.colors||t.split(".")[0]in e.colors)?r:t===void 0?e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4]:t}var VE=Q((e,{size:t,variant:r,color:n})=>({root:{},withLabel:{borderTop:"0 !important"},left:{"&::before":{display:"none"}},right:{"&::after":{display:"none"}},label:{display:"flex",alignItems:"center","&::before":{content:'""',flex:1,height:1,borderTop:`${e.fn.size({size:t,sizes:gl})}px ${r} ${ml(e,n)}`,marginRight:e.spacing.xs},"&::after":{content:'""',flex:1,borderTop:`${e.fn.size({size:t,sizes:gl})}px ${r} ${ml(e,n)}`,marginLeft:e.spacing.xs}},labelDefaultStyles:{color:n==="dark"?e.colors.dark[1]:e.fn.themeColor(n,e.colorScheme==="dark"?5:e.fn.primaryShade(),!1)},horizontal:{border:0,borderTopWidth:e.fn.size({size:t,sizes:gl}),borderTopColor:ml(e,n),borderTopStyle:r,margin:0},vertical:{border:0,alignSelf:"stretch",height:"auto",borderLeftWidth:e.fn.size({size:t,sizes:gl}),borderLeftColor:ml(e,n),borderLeftStyle:r}})),HE=VE,BE=Object.defineProperty,WE=Object.defineProperties,UE=Object.getOwnPropertyDescriptors,$a=Object.getOwnPropertySymbols,Pw=Object.prototype.hasOwnProperty,$w=Object.prototype.propertyIsEnumerable,Im=(e,t,r)=>t in e?BE(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Nm=(e,t)=>{for(var r in t||(t={}))Pw.call(t,r)&&Im(e,r,t[r]);if($a)for(var r of $a(t))$w.call(t,r)&&Im(e,r,t[r]);return e},GE=(e,t)=>WE(e,UE(t)),YE=(e,t)=>{var r={};for(var n in e)Pw.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&$a)for(var n of $a(e))t.indexOf(n)<0&&$w.call(e,n)&&(r[n]=e[n]);return r};const XE={orientation:"horizontal",size:"xs",labelPosition:"left",variant:"solid"},df=g.exports.forwardRef((e,t)=>{const r=ee("Divider",XE,e),{className:n,color:o,orientation:i,size:l,label:a,labelPosition:s,labelProps:u,variant:c,styles:f,classNames:d,unstyled:p}=r,y=YE(r,["className","color","orientation","size","label","labelPosition","labelProps","variant","styles","classNames","unstyled"]),{classes:w,cx:v}=HE({color:o,size:l,variant:c},{classNames:d,styles:f,unstyled:p,name:"Divider"}),m=i==="vertical",h=i==="horizontal",_=!!a&&h,b=!u?.color;return S(q,{...Nm({ref:t,className:v(w.root,{[w.vertical]:m,[w.horizontal]:h,[w.withLabel]:_},n),role:"separator"},y),children:_&&S(mt,{...GE(Nm({},u),{size:u?.size||"xs",sx:{marginTop:2},className:v(w.label,w[s],{[w.labelDefaultStyles]:b})}),children:a})})});df.displayName="@mantine/core/Divider";var qE=Object.defineProperty,zm=Object.getOwnPropertySymbols,KE=Object.prototype.hasOwnProperty,QE=Object.prototype.propertyIsEnumerable,Dm=(e,t,r)=>t in e?qE(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,ZE=(e,t)=>{for(var r in t||(t={}))KE.call(t,r)&&Dm(e,r,t[r]);if(zm)for(var r of zm(t))QE.call(t,r)&&Dm(e,r,t[r]);return e},JE=Q((e,{size:t})=>({item:{boxSizing:"border-box",textAlign:"left",width:"100%",padding:`${e.fn.size({size:t,sizes:e.spacing})/1.5}px ${e.fn.size({size:t,sizes:e.spacing})}px`,cursor:"pointer",fontSize:e.fn.size({size:t,sizes:e.fontSizes}),color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,borderRadius:e.radius.sm,"&[data-hovered]":{backgroundColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[1]},"&[data-selected]":ZE({backgroundColor:e.fn.variant({variant:"filled"}).background,color:e.fn.variant({variant:"filled"}).color},e.fn.hover({backgroundColor:e.fn.variant({variant:"filled"}).hover})),"&[data-disabled]":{cursor:"default",color:e.colors.dark[2]}},nothingFound:{boxSizing:"border-box",color:e.colors.gray[6],paddingTop:e.fn.size({size:t,sizes:e.spacing})/2,paddingBottom:e.fn.size({size:t,sizes:e.spacing})/2,textAlign:"center"},separator:{boxSizing:"border-box",textAlign:"left",width:"100%",padding:`${e.fn.size({size:t,sizes:e.spacing})/1.5}px ${e.fn.size({size:t,sizes:e.spacing})}px`},separatorLabel:{color:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[5]}})),ek=JE,tk=Object.defineProperty,Tm=Object.getOwnPropertySymbols,rk=Object.prototype.hasOwnProperty,nk=Object.prototype.propertyIsEnumerable,Mm=(e,t,r)=>t in e?tk(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,ok=(e,t)=>{for(var r in t||(t={}))rk.call(t,r)&&Mm(e,r,t[r]);if(Tm)for(var r of Tm(t))nk.call(t,r)&&Mm(e,r,t[r]);return e};function Ow({data:e,hovered:t,classNames:r,styles:n,isItemSelected:o,uuid:i,__staticSelector:l,onItemHover:a,onItemSelect:s,itemsRefs:u,itemComponent:c,size:f,nothingFound:d,creatable:p,createLabel:y,unstyled:w}){const{classes:v}=ek({size:f},{classNames:r,styles:n,unstyled:w,name:l}),m=[],h=[];let _=null;const b=(x,P)=>{const $=typeof o=="function"?o(x.value):!1;return E.createElement(c,ok({key:x.value,className:v.item,"data-disabled":x.disabled||void 0,"data-hovered":!x.disabled&&t===P||void 0,"data-selected":!x.disabled&&$||void 0,onMouseEnter:()=>a(P),id:`${i}-${P}`,role:"option","data-ignore-outside-clicks":!0,tabIndex:-1,"aria-selected":t===P,ref:C=>{u&&u.current&&(u.current[x.value]=C)},onMouseDown:x.disabled?null:C=>{C.preventDefault(),s(x)},disabled:x.disabled},x))};let O=null;if(e.forEach((x,P)=>{x.creatable?_=P:x.group?(O!==x.group&&(O=x.group,h.push(E.createElement("div",{className:v.separator,key:`__mantine-divider-${P}`},E.createElement(df,{classNames:{label:v.separatorLabel},label:x.group})))),h.push(b(x,P))):m.push(b(x,P))}),p){const x=e[_];m.push(E.createElement("div",{key:Al(),className:v.item,"data-hovered":t===_||void 0,onMouseEnter:()=>a(_),onMouseDown:P=>{P.preventDefault(),s(x)},tabIndex:-1,ref:P=>{u&&u.current&&(u.current[x.value]=P)}},y))}return h.length>0&&m.length>0&&m.unshift(E.createElement("div",{className:v.separator,key:"empty-group-separator"},E.createElement(df,null))),h.length>0||m.length>0?E.createElement(E.Fragment,null,h,m):E.createElement(mt,{size:f,unstyled:w,className:v.nothingFound},d)}Ow.displayName="@mantine/core/SelectItems";var ik=Object.defineProperty,Oa=Object.getOwnPropertySymbols,Cw=Object.prototype.hasOwnProperty,Ew=Object.prototype.propertyIsEnumerable,jm=(e,t,r)=>t in e?ik(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,lk=(e,t)=>{for(var r in t||(t={}))Cw.call(t,r)&&jm(e,r,t[r]);if(Oa)for(var r of Oa(t))Ew.call(t,r)&&jm(e,r,t[r]);return e},ak=(e,t)=>{var r={};for(var n in e)Cw.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Oa)for(var n of Oa(e))t.indexOf(n)<0&&Ew.call(e,n)&&(r[n]=e[n]);return r};const kw=g.exports.forwardRef((e,t)=>{var r=e,{label:n,value:o}=r,i=ak(r,["label","value"]);return S("div",{...lk({ref:t},i),children:n||o})});kw.displayName="@mantine/core/DefaultItem";function sk(e,t){typeof e=="function"?e(t):e!=null&&(e.current=t)}function Rw(...e){return t=>e.forEach(r=>sk(r,t))}function gn(...e){return g.exports.useCallback(Rw(...e),e)}const Iw=g.exports.forwardRef((e,t)=>{const{children:r,...n}=e,o=g.exports.Children.toArray(r),i=o.find(ck);if(i){const l=i.props.children,a=o.map(s=>s===i?g.exports.Children.count(l)>1?g.exports.Children.only(null):g.exports.isValidElement(l)?l.props.children:null:s);return g.exports.createElement(pf,ge({},n,{ref:t}),g.exports.isValidElement(l)?g.exports.cloneElement(l,void 0,a):null)}return g.exports.createElement(pf,ge({},n,{ref:t}),r)});Iw.displayName="Slot";const pf=g.exports.forwardRef((e,t)=>{const{children:r,...n}=e;return g.exports.isValidElement(r)?g.exports.cloneElement(r,{...fk(n,r.props),ref:Rw(t,r.ref)}):g.exports.Children.count(r)>1?g.exports.Children.only(null):null});pf.displayName="SlotClone";const uk=({children:e})=>g.exports.createElement(g.exports.Fragment,null,e);function ck(e){return g.exports.isValidElement(e)&&e.type===uk}function fk(e,t){const r={...t};for(const n in t){const o=e[n],i=t[n];/^on[A-Z]/.test(n)?r[n]=(...a)=>{i?.(...a),o?.(...a)}:n==="style"?r[n]={...o,...i}:n==="className"&&(r[n]=[o,i].filter(Boolean).join(" "))}return{...e,...r}}const dk=["a","button","div","h2","h3","img","li","nav","ol","p","span","svg","ul"],Ai=dk.reduce((e,t)=>{const r=g.exports.forwardRef((n,o)=>{const{asChild:i,...l}=n,a=i?Iw:t;return g.exports.useEffect(()=>{window[Symbol.for("radix-ui")]=!0},[]),g.exports.createElement(a,ge({},l,{ref:o}))});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{}),gf=Boolean(globalThis?.document)?g.exports.useLayoutEffect:()=>{};function pk(e,t){return g.exports.useReducer((r,n)=>{const o=t[r][n];return o??r},e)}const Vi=e=>{const{present:t,children:r}=e,n=gk(t),o=typeof r=="function"?r({present:n.isPresent}):g.exports.Children.only(r),i=gn(n.ref,o.ref);return typeof r=="function"||n.isPresent?g.exports.cloneElement(o,{ref:i}):null};Vi.displayName="Presence";function gk(e){const[t,r]=g.exports.useState(),n=g.exports.useRef({}),o=g.exports.useRef(e),i=g.exports.useRef("none"),l=e?"mounted":"unmounted",[a,s]=pk(l,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return g.exports.useEffect(()=>{const u=vl(n.current);i.current=a==="mounted"?u:"none"},[a]),gf(()=>{const u=n.current,c=o.current;if(c!==e){const d=i.current,p=vl(u);e?s("MOUNT"):p==="none"||u?.display==="none"?s("UNMOUNT"):s(c&&d!==p?"ANIMATION_OUT":"UNMOUNT"),o.current=e}},[e,s]),gf(()=>{if(t){const u=f=>{const p=vl(n.current).includes(f.animationName);f.target===t&&p&&Ei.exports.flushSync(()=>s("ANIMATION_END"))},c=f=>{f.target===t&&(i.current=vl(n.current))};return t.addEventListener("animationstart",c),t.addEventListener("animationcancel",u),t.addEventListener("animationend",u),()=>{t.removeEventListener("animationstart",c),t.removeEventListener("animationcancel",u),t.removeEventListener("animationend",u)}}else s("ANIMATION_END")},[t,s]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:g.exports.useCallback(u=>{u&&(n.current=getComputedStyle(u)),r(u)},[])}}function vl(e){return e?.animationName||"none"}function mk(e,t=[]){let r=[];function n(i,l){const a=g.exports.createContext(l),s=r.length;r=[...r,l];function u(f){const{scope:d,children:p,...y}=f,w=d?.[e][s]||a,v=g.exports.useMemo(()=>y,Object.values(y));return g.exports.createElement(w.Provider,{value:v},p)}function c(f,d){const p=d?.[e][s]||a,y=g.exports.useContext(p);if(y)return y;if(l!==void 0)return l;throw new Error(`\`${f}\` must be used within \`${i}\``)}return u.displayName=i+"Provider",[u,c]}const o=()=>{const i=r.map(l=>g.exports.createContext(l));return function(a){const s=a?.[e]||i;return g.exports.useMemo(()=>({[`__scope${e}`]:{...a,[e]:s}}),[a,s])}};return o.scopeName=e,[n,vk(o,...t)]}function vk(...e){const t=e[0];if(e.length===1)return t;const r=()=>{const n=e.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(i){const l=n.reduce((a,{useScope:s,scopeName:u})=>{const f=s(i)[`__scope${u}`];return{...a,...f}},{});return g.exports.useMemo(()=>({[`__scope${t.scopeName}`]:l}),[l])}};return r.scopeName=t.scopeName,r}function Ur(e){const t=g.exports.useRef(e);return g.exports.useEffect(()=>{t.current=e}),g.exports.useMemo(()=>(...r)=>{var n;return(n=t.current)===null||n===void 0?void 0:n.call(t,...r)},[])}const hk=g.exports.createContext(void 0);function yk(e){const t=g.exports.useContext(hk);return e||t||"ltr"}function wk(e,[t,r]){return Math.min(r,Math.max(t,e))}function en(e,t,{checkForDefaultPrevented:r=!0}={}){return function(o){if(e?.(o),r===!1||!o.defaultPrevented)return t?.(o)}}function _k(e,t){return g.exports.useReducer((r,n)=>{const o=t[r][n];return o??r},e)}const Nw="ScrollArea",[zw,l7]=mk(Nw),[Sk,yt]=zw(Nw),bk=g.exports.forwardRef((e,t)=>{const{__scopeScrollArea:r,type:n="hover",dir:o,scrollHideDelay:i=600,...l}=e,[a,s]=g.exports.useState(null),[u,c]=g.exports.useState(null),[f,d]=g.exports.useState(null),[p,y]=g.exports.useState(null),[w,v]=g.exports.useState(null),[m,h]=g.exports.useState(0),[_,b]=g.exports.useState(0),[O,x]=g.exports.useState(!1),[P,$]=g.exports.useState(!1),C=gn(t,z=>s(z)),I=yk(o);return g.exports.createElement(Sk,{scope:r,type:n,dir:I,scrollHideDelay:i,scrollArea:a,viewport:u,onViewportChange:c,content:f,onContentChange:d,scrollbarX:p,onScrollbarXChange:y,scrollbarXEnabled:O,onScrollbarXEnabledChange:x,scrollbarY:w,onScrollbarYChange:v,scrollbarYEnabled:P,onScrollbarYEnabledChange:$,onCornerWidthChange:h,onCornerHeightChange:b},g.exports.createElement(Ai.div,ge({dir:I},l,{ref:C,style:{position:"relative",["--radix-scroll-area-corner-width"]:m+"px",["--radix-scroll-area-corner-height"]:_+"px",...e.style}})))}),xk="ScrollAreaViewport",Pk=g.exports.forwardRef((e,t)=>{const{__scopeScrollArea:r,children:n,...o}=e,i=yt(xk,r),l=g.exports.useRef(null),a=gn(t,l,i.onViewportChange);return g.exports.createElement(g.exports.Fragment,null,g.exports.createElement("style",{dangerouslySetInnerHTML:{__html:"[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}"}}),g.exports.createElement(Ai.div,ge({"data-radix-scroll-area-viewport":""},o,{ref:a,style:{overflowX:i.scrollbarXEnabled?"scroll":"hidden",overflowY:i.scrollbarYEnabled?"scroll":"hidden",...e.style}}),g.exports.createElement("div",{ref:i.onContentChange,style:{minWidth:"100%",display:"table"}},n)))}),tr="ScrollAreaScrollbar",$k=g.exports.forwardRef((e,t)=>{const{forceMount:r,...n}=e,o=yt(tr,e.__scopeScrollArea),{onScrollbarXEnabledChange:i,onScrollbarYEnabledChange:l}=o,a=e.orientation==="horizontal";return g.exports.useEffect(()=>(a?i(!0):l(!0),()=>{a?i(!1):l(!1)}),[a,i,l]),o.type==="hover"?g.exports.createElement(Ok,ge({},n,{ref:t,forceMount:r})):o.type==="scroll"?g.exports.createElement(Ck,ge({},n,{ref:t,forceMount:r})):o.type==="auto"?g.exports.createElement(Dw,ge({},n,{ref:t,forceMount:r})):o.type==="always"?g.exports.createElement(Wd,ge({},n,{ref:t})):null}),Ok=g.exports.forwardRef((e,t)=>{const{forceMount:r,...n}=e,o=yt(tr,e.__scopeScrollArea),[i,l]=g.exports.useState(!1);return g.exports.useEffect(()=>{const a=o.scrollArea;let s=0;if(a){const u=()=>{window.clearTimeout(s),l(!0)},c=()=>{s=window.setTimeout(()=>l(!1),o.scrollHideDelay)};return a.addEventListener("pointerenter",u),a.addEventListener("pointerleave",c),()=>{window.clearTimeout(s),a.removeEventListener("pointerenter",u),a.removeEventListener("pointerleave",c)}}},[o.scrollArea,o.scrollHideDelay]),g.exports.createElement(Vi,{present:r||i},g.exports.createElement(Dw,ge({"data-state":i?"visible":"hidden"},n,{ref:t})))}),Ck=g.exports.forwardRef((e,t)=>{const{forceMount:r,...n}=e,o=yt(tr,e.__scopeScrollArea),i=e.orientation==="horizontal",l=au(()=>s("SCROLL_END"),100),[a,s]=_k("hidden",{hidden:{SCROLL:"scrolling"},scrolling:{SCROLL_END:"idle",POINTER_ENTER:"interacting"},interacting:{SCROLL:"interacting",POINTER_LEAVE:"idle"},idle:{HIDE:"hidden",SCROLL:"scrolling",POINTER_ENTER:"interacting"}});return g.exports.useEffect(()=>{if(a==="idle"){const u=window.setTimeout(()=>s("HIDE"),o.scrollHideDelay);return()=>window.clearTimeout(u)}},[a,o.scrollHideDelay,s]),g.exports.useEffect(()=>{const u=o.viewport,c=i?"scrollLeft":"scrollTop";if(u){let f=u[c];const d=()=>{const p=u[c];f!==p&&(s("SCROLL"),l()),f=p};return u.addEventListener("scroll",d),()=>u.removeEventListener("scroll",d)}},[o.viewport,i,s,l]),g.exports.createElement(Vi,{present:r||a!=="hidden"},g.exports.createElement(Wd,ge({"data-state":a==="hidden"?"hidden":"visible"},n,{ref:t,onPointerEnter:en(e.onPointerEnter,()=>s("POINTER_ENTER")),onPointerLeave:en(e.onPointerLeave,()=>s("POINTER_LEAVE"))})))}),Dw=g.exports.forwardRef((e,t)=>{const r=yt(tr,e.__scopeScrollArea),{forceMount:n,...o}=e,[i,l]=g.exports.useState(!1),a=e.orientation==="horizontal",s=au(()=>{if(r.viewport){const u=r.viewport.offsetWidth{const{orientation:r="vertical",...n}=e,o=yt(tr,e.__scopeScrollArea),i=g.exports.useRef(null),l=g.exports.useRef(0),[a,s]=g.exports.useState({content:0,viewport:0,scrollbar:{size:0,paddingStart:0,paddingEnd:0}}),u=Lw(a.viewport,a.content),c={...n,sizes:a,onSizesChange:s,hasThumb:Boolean(u>0&&u<1),onThumbChange:d=>i.current=d,onThumbPointerUp:()=>l.current=0,onThumbPointerDown:d=>l.current=d};function f(d,p){return Tk(d,l.current,a,p)}return r==="horizontal"?g.exports.createElement(Ek,ge({},c,{ref:t,onThumbPositionChange:()=>{if(o.viewport&&i.current){const d=o.viewport.scrollLeft,p=Lm(d,a,o.dir);i.current.style.transform=`translate3d(${p}px, 0, 0)`}},onWheelScroll:d=>{o.viewport&&(o.viewport.scrollLeft=d)},onDragScroll:d=>{o.viewport&&(o.viewport.scrollLeft=f(d,o.dir))}})):r==="vertical"?g.exports.createElement(kk,ge({},c,{ref:t,onThumbPositionChange:()=>{if(o.viewport&&i.current){const d=o.viewport.scrollTop,p=Lm(d,a);i.current.style.transform=`translate3d(0, ${p}px, 0)`}},onWheelScroll:d=>{o.viewport&&(o.viewport.scrollTop=d)},onDragScroll:d=>{o.viewport&&(o.viewport.scrollTop=f(d))}})):null}),Ek=g.exports.forwardRef((e,t)=>{const{sizes:r,onSizesChange:n,...o}=e,i=yt(tr,e.__scopeScrollArea),[l,a]=g.exports.useState(),s=g.exports.useRef(null),u=gn(t,s,i.onScrollbarXChange);return g.exports.useEffect(()=>{s.current&&a(getComputedStyle(s.current))},[s]),g.exports.createElement(Mw,ge({"data-orientation":"horizontal"},o,{ref:u,sizes:r,style:{bottom:0,left:i.dir==="rtl"?"var(--radix-scroll-area-corner-width)":0,right:i.dir==="ltr"?"var(--radix-scroll-area-corner-width)":0,["--radix-scroll-area-thumb-width"]:lu(r)+"px",...e.style},onThumbPointerDown:c=>e.onThumbPointerDown(c.x),onDragScroll:c=>e.onDragScroll(c.x),onWheelScroll:(c,f)=>{if(i.viewport){const d=i.viewport.scrollLeft+c.deltaX;e.onWheelScroll(d),Aw(d,f)&&c.preventDefault()}},onResize:()=>{s.current&&i.viewport&&l&&n({content:i.viewport.scrollWidth,viewport:i.viewport.offsetWidth,scrollbar:{size:s.current.clientWidth,paddingStart:Ca(l.paddingLeft),paddingEnd:Ca(l.paddingRight)}})}}))}),kk=g.exports.forwardRef((e,t)=>{const{sizes:r,onSizesChange:n,...o}=e,i=yt(tr,e.__scopeScrollArea),[l,a]=g.exports.useState(),s=g.exports.useRef(null),u=gn(t,s,i.onScrollbarYChange);return g.exports.useEffect(()=>{s.current&&a(getComputedStyle(s.current))},[s]),g.exports.createElement(Mw,ge({"data-orientation":"vertical"},o,{ref:u,sizes:r,style:{top:0,right:i.dir==="ltr"?0:void 0,left:i.dir==="rtl"?0:void 0,bottom:"var(--radix-scroll-area-corner-height)",["--radix-scroll-area-thumb-height"]:lu(r)+"px",...e.style},onThumbPointerDown:c=>e.onThumbPointerDown(c.y),onDragScroll:c=>e.onDragScroll(c.y),onWheelScroll:(c,f)=>{if(i.viewport){const d=i.viewport.scrollTop+c.deltaY;e.onWheelScroll(d),Aw(d,f)&&c.preventDefault()}},onResize:()=>{s.current&&i.viewport&&l&&n({content:i.viewport.scrollHeight,viewport:i.viewport.offsetHeight,scrollbar:{size:s.current.clientHeight,paddingStart:Ca(l.paddingTop),paddingEnd:Ca(l.paddingBottom)}})}}))}),[Rk,Tw]=zw(tr),Mw=g.exports.forwardRef((e,t)=>{const{__scopeScrollArea:r,sizes:n,hasThumb:o,onThumbChange:i,onThumbPointerUp:l,onThumbPointerDown:a,onThumbPositionChange:s,onDragScroll:u,onWheelScroll:c,onResize:f,...d}=e,p=yt(tr,r),[y,w]=g.exports.useState(null),v=gn(t,C=>w(C)),m=g.exports.useRef(null),h=g.exports.useRef(""),_=p.viewport,b=n.content-n.viewport,O=Ur(c),x=Ur(s),P=au(f,10);function $(C){if(m.current){const I=C.clientX-m.current.left,z=C.clientY-m.current.top;u({x:I,y:z})}}return g.exports.useEffect(()=>{const C=I=>{const z=I.target;y?.contains(z)&&O(I,b)};return document.addEventListener("wheel",C,{passive:!1}),()=>document.removeEventListener("wheel",C,{passive:!1})},[_,y,b,O]),g.exports.useEffect(x,[n,x]),Xn(y,P),Xn(p.content,P),g.exports.createElement(Rk,{scope:r,scrollbar:y,hasThumb:o,onThumbChange:Ur(i),onThumbPointerUp:Ur(l),onThumbPositionChange:x,onThumbPointerDown:Ur(a)},g.exports.createElement(Ai.div,ge({},d,{ref:v,style:{position:"absolute",...d.style},onPointerDown:en(e.onPointerDown,C=>{C.button===0&&(C.target.setPointerCapture(C.pointerId),m.current=y.getBoundingClientRect(),h.current=document.body.style.webkitUserSelect,document.body.style.webkitUserSelect="none",$(C))}),onPointerMove:en(e.onPointerMove,$),onPointerUp:en(e.onPointerUp,C=>{C.target.releasePointerCapture(C.pointerId),document.body.style.webkitUserSelect=h.current,m.current=null})})))}),mf="ScrollAreaThumb",Ik=g.exports.forwardRef((e,t)=>{const{forceMount:r,...n}=e,o=Tw(mf,e.__scopeScrollArea);return g.exports.createElement(Vi,{present:r||o.hasThumb},g.exports.createElement(Nk,ge({ref:t},n)))}),Nk=g.exports.forwardRef((e,t)=>{const{__scopeScrollArea:r,style:n,...o}=e,i=yt(mf,r),l=Tw(mf,r),{onThumbPositionChange:a}=l,s=gn(t,f=>l.onThumbChange(f)),u=g.exports.useRef(),c=au(()=>{u.current&&(u.current(),u.current=void 0)},100);return g.exports.useEffect(()=>{const f=i.viewport;if(f){const d=()=>{if(c(),!u.current){const p=Mk(f,a);u.current=p,a()}};return a(),f.addEventListener("scroll",d),()=>f.removeEventListener("scroll",d)}},[i.viewport,c,a]),g.exports.createElement(Ai.div,ge({"data-state":l.hasThumb?"visible":"hidden"},o,{ref:s,style:{width:"var(--radix-scroll-area-thumb-width)",height:"var(--radix-scroll-area-thumb-height)",...n},onPointerDownCapture:en(e.onPointerDownCapture,f=>{const p=f.target.getBoundingClientRect(),y=f.clientX-p.left,w=f.clientY-p.top;l.onThumbPointerDown({x:y,y:w})}),onPointerUp:en(e.onPointerUp,l.onThumbPointerUp)}))}),jw="ScrollAreaCorner",zk=g.exports.forwardRef((e,t)=>{const r=yt(jw,e.__scopeScrollArea),n=Boolean(r.scrollbarX&&r.scrollbarY);return r.type!=="scroll"&&n?g.exports.createElement(Dk,ge({},e,{ref:t})):null}),Dk=g.exports.forwardRef((e,t)=>{const{__scopeScrollArea:r,...n}=e,o=yt(jw,r),[i,l]=g.exports.useState(0),[a,s]=g.exports.useState(0),u=Boolean(i&&a);return Xn(o.scrollbarX,()=>{var c;const f=((c=o.scrollbarX)===null||c===void 0?void 0:c.offsetHeight)||0;o.onCornerHeightChange(f),s(f)}),Xn(o.scrollbarY,()=>{var c;const f=((c=o.scrollbarY)===null||c===void 0?void 0:c.offsetWidth)||0;o.onCornerWidthChange(f),l(f)}),u?g.exports.createElement(Ai.div,ge({},n,{ref:t,style:{width:i,height:a,position:"absolute",right:o.dir==="ltr"?0:void 0,left:o.dir==="rtl"?0:void 0,bottom:0,...e.style}})):null});function Ca(e){return e?parseInt(e,10):0}function Lw(e,t){const r=e/t;return isNaN(r)?0:r}function lu(e){const t=Lw(e.viewport,e.content),r=e.scrollbar.paddingStart+e.scrollbar.paddingEnd,n=(e.scrollbar.size-r)*t;return Math.max(n,18)}function Tk(e,t,r,n="ltr"){const o=lu(r),i=o/2,l=t||i,a=o-l,s=r.scrollbar.paddingStart+l,u=r.scrollbar.size-r.scrollbar.paddingEnd-a,c=r.content-r.viewport,f=n==="ltr"?[0,c]:[c*-1,0];return Fw([s,u],f)(e)}function Lm(e,t,r="ltr"){const n=lu(t),o=t.scrollbar.paddingStart+t.scrollbar.paddingEnd,i=t.scrollbar.size-o,l=t.content-t.viewport,a=i-n,s=r==="ltr"?[0,l]:[l*-1,0],u=wk(e,s);return Fw([0,l],[0,a])(u)}function Fw(e,t){return r=>{if(e[0]===e[1]||t[0]===t[1])return t[0];const n=(t[1]-t[0])/(e[1]-e[0]);return t[0]+n*(r-e[0])}}function Aw(e,t){return e>0&&e{})=>{let r={left:e.scrollLeft,top:e.scrollTop},n=0;return function o(){const i={left:e.scrollLeft,top:e.scrollTop},l=r.left!==i.left,a=r.top!==i.top;(l||a)&&t(),r=i,n=window.requestAnimationFrame(o)}(),()=>window.cancelAnimationFrame(n)};function au(e,t){const r=Ur(e),n=g.exports.useRef(0);return g.exports.useEffect(()=>()=>window.clearTimeout(n.current),[]),g.exports.useCallback(()=>{window.clearTimeout(n.current),n.current=window.setTimeout(r,t)},[r,t])}function Xn(e,t){const r=Ur(t);gf(()=>{let n=0;if(e){const o=new ResizeObserver(()=>{cancelAnimationFrame(n),n=window.requestAnimationFrame(r)});return o.observe(e),()=>{window.cancelAnimationFrame(n),o.unobserve(e)}}},[e,r])}const jk=bk,Lk=Pk,Fm=$k,Am=Ik,Fk=zk;var Ak=Q((e,{scrollbarSize:t,offsetScrollbars:r,scrollbarHovered:n,hidden:o},i)=>({root:{overflow:"hidden"},viewport:{width:"100%",height:"100%",paddingRight:r?t:void 0},scrollbar:{display:o?"none":"flex",userSelect:"none",touchAction:"none",boxSizing:"border-box",padding:t/5,transition:"background-color 150ms ease, opacity 150ms ease","&:hover":{backgroundColor:e.colorScheme==="dark"?e.colors.dark[8]:e.colors.gray[0],[`& .${i("thumb")}`]:{backgroundColor:e.colorScheme==="dark"?e.fn.rgba(e.white,.5):e.fn.rgba(e.black,.5)}},'&[data-orientation="vertical"]':{width:t},'&[data-orientation="horizontal"]':{flexDirection:"column",height:t},'&[data-state="hidden"]':{display:"none",opacity:0}},thumb:{ref:i("thumb"),flex:1,backgroundColor:e.colorScheme==="dark"?e.fn.rgba(e.white,.4):e.fn.rgba(e.black,.4),borderRadius:t,position:"relative",transition:"background-color 150ms ease",display:o?"none":void 0,"&::before":{content:'""',position:"absolute",top:"50%",left:"50%",transform:"translate(-50%, -50%)",width:"100%",height:"100%",minWidth:44,minHeight:44}},corner:{backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[0],transition:"opacity 150ms ease",opacity:n?1:0,display:o?"none":void 0}})),Vk=Ak,Hk=Object.defineProperty,Bk=Object.defineProperties,Wk=Object.getOwnPropertyDescriptors,Ea=Object.getOwnPropertySymbols,Vw=Object.prototype.hasOwnProperty,Hw=Object.prototype.propertyIsEnumerable,Vm=(e,t,r)=>t in e?Hk(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Bw=(e,t)=>{for(var r in t||(t={}))Vw.call(t,r)&&Vm(e,r,t[r]);if(Ea)for(var r of Ea(t))Hw.call(t,r)&&Vm(e,r,t[r]);return e},Uk=(e,t)=>Bk(e,Wk(t)),Ww=(e,t)=>{var r={};for(var n in e)Vw.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Ea)for(var n of Ea(e))t.indexOf(n)<0&&Hw.call(e,n)&&(r[n]=e[n]);return r};const Uw={scrollbarSize:12,scrollHideDelay:1e3,type:"hover",offsetScrollbars:!1},su=g.exports.forwardRef((e,t)=>{const r=ee("ScrollArea",Uw,e),{children:n,className:o,classNames:i,styles:l,scrollbarSize:a,scrollHideDelay:s,type:u,dir:c,offsetScrollbars:f,viewportRef:d,onScrollPositionChange:p,unstyled:y}=r,w=Ww(r,["children","className","classNames","styles","scrollbarSize","scrollHideDelay","type","dir","offsetScrollbars","viewportRef","onScrollPositionChange","unstyled"]),[v,m]=g.exports.useState(!1),h=at(),{classes:_,cx:b}=Vk({scrollbarSize:a,offsetScrollbars:f,scrollbarHovered:v,hidden:u==="never"},{name:"ScrollArea",classNames:i,styles:l,unstyled:y});return S(jk,{type:u==="never"?"always":u,scrollHideDelay:s,dir:c||h.dir,ref:t,asChild:!0,children:U(q,{...Bw({className:b(_.root,o)},w),children:[S(Lk,{className:_.viewport,ref:d,onScroll:typeof p=="function"?({currentTarget:O})=>p({x:O.scrollLeft,y:O.scrollTop}):void 0,children:n}),S(Fm,{orientation:"horizontal",className:_.scrollbar,forceMount:!0,onMouseEnter:()=>m(!0),onMouseLeave:()=>m(!1),children:S(Am,{className:_.thumb})}),S(Fm,{orientation:"vertical",className:_.scrollbar,forceMount:!0,onMouseEnter:()=>m(!0),onMouseLeave:()=>m(!1),children:S(Am,{className:_.thumb})}),S(Fk,{className:_.corner})]})})}),Gw=g.exports.forwardRef((e,t)=>{const r=ee("ScrollAreaAutosize",Uw,e),{maxHeight:n,children:o,classNames:i,styles:l,scrollbarSize:a,scrollHideDelay:s,type:u,dir:c,offsetScrollbars:f,viewportRef:d,onScrollPositionChange:p,unstyled:y,sx:w}=r,v=Ww(r,["maxHeight","children","classNames","styles","scrollbarSize","scrollHideDelay","type","dir","offsetScrollbars","viewportRef","onScrollPositionChange","unstyled","sx"]);return E.createElement(q,Uk(Bw({},v),{ref:t,sx:[{display:"flex",maxHeight:n},...Si(w)]}),E.createElement(q,{sx:{display:"flex",flexDirection:"column",flex:1}},E.createElement(su,{classNames:i,styles:l,scrollHideDelay:s,scrollbarSize:a,type:u,dir:c,offsetScrollbars:f,viewportRef:d,onScrollPositionChange:p,unstyled:y},o)))});Gw.displayName="@mantine/core/ScrollAreaAutosize";su.displayName="@mantine/core/ScrollArea";su.Autosize=Gw;const Gk=su;var Yk=Object.defineProperty,Xk=Object.defineProperties,qk=Object.getOwnPropertyDescriptors,ka=Object.getOwnPropertySymbols,Yw=Object.prototype.hasOwnProperty,Xw=Object.prototype.propertyIsEnumerable,Hm=(e,t,r)=>t in e?Yk(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Bm=(e,t)=>{for(var r in t||(t={}))Yw.call(t,r)&&Hm(e,r,t[r]);if(ka)for(var r of ka(t))Xw.call(t,r)&&Hm(e,r,t[r]);return e},Kk=(e,t)=>Xk(e,qk(t)),Qk=(e,t)=>{var r={};for(var n in e)Yw.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&ka)for(var n of ka(e))t.indexOf(n)<0&&Xw.call(e,n)&&(r[n]=e[n]);return r};const Ud=g.exports.forwardRef((e,t)=>{var r=e,{style:n}=r,o=Qk(r,["style"]);return S(Gk,{...Kk(Bm({},o),{style:Bm({width:"100%"},n),viewportRef:t}),children:o.children})});Ud.displayName="@mantine/core/SelectScrollArea";function ao(e){return e.split("-")[0]}function uu(e){return e.split("-")[1]}function cu(e){return["top","bottom"].includes(ao(e))?"x":"y"}function qw(e){return e==="y"?"height":"width"}function Wm(e,t,r){let{reference:n,floating:o}=e;const i=n.x+n.width/2-o.width/2,l=n.y+n.height/2-o.height/2,a=cu(t),s=qw(a),u=n[s]/2-o[s]/2,c=ao(t),f=a==="x";let d;switch(c){case"top":d={x:i,y:n.y-o.height};break;case"bottom":d={x:i,y:n.y+n.height};break;case"right":d={x:n.x+n.width,y:l};break;case"left":d={x:n.x-o.width,y:l};break;default:d={x:n.x,y:n.y}}switch(uu(t)){case"start":d[a]-=u*(r&&f?-1:1);break;case"end":d[a]+=u*(r&&f?-1:1);break}return d}const Zk=async(e,t,r)=>{const{placement:n="bottom",strategy:o="absolute",middleware:i=[],platform:l}=r,a=await(l.isRTL==null?void 0:l.isRTL(t));let s=await l.getElementRects({reference:e,floating:t,strategy:o}),{x:u,y:c}=Wm(s,n,a),f=n,d={},p=0;for(let y=0;yr3[t])}function n3(e,t,r){r===void 0&&(r=!1);const n=uu(e),o=cu(e),i=qw(o);let l=o==="x"?n===(r?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(l=Ia(l)),{main:l,cross:Ia(l)}}const o3={start:"end",end:"start"};function Gm(e){return e.replace(/start|end/g,t=>o3[t])}function i3(e){const t=Ia(e);return[Gm(e),t,Gm(t)]}const Kw=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var r;const{placement:n,middlewareData:o,rects:i,initialPlacement:l,platform:a,elements:s}=t,{mainAxis:u=!0,crossAxis:c=!0,fallbackPlacements:f,fallbackStrategy:d="bestFit",flipAlignment:p=!0,...y}=e,w=ao(n),m=f||(w===l||!p?[Ia(l)]:i3(l)),h=[l,...m],_=await Gd(t,y),b=[];let O=((r=o.flip)==null?void 0:r.overflows)||[];if(u&&b.push(_[w]),c){const{main:C,cross:I}=n3(n,i,await(a.isRTL==null?void 0:a.isRTL(s.floating)));b.push(_[C],_[I])}if(O=[...O,{placement:n,overflows:b}],!b.every(C=>C<=0)){var x,P;const C=((x=(P=o.flip)==null?void 0:P.index)!=null?x:0)+1,I=h[C];if(I)return{data:{index:C,overflows:O},reset:{placement:I}};let z="bottom";switch(d){case"bestFit":{var $;const D=($=O.map(j=>[j,j.overflows.filter(B=>B>0).reduce((B,V)=>B+V,0)]).sort((j,B)=>j[1]-B[1])[0])==null?void 0:$[0].placement;D&&(z=D);break}case"initialPlacement":z=l;break}if(n!==z)return{reset:{placement:z}}}return{}}}};async function l3(e,t){const{placement:r,platform:n,elements:o}=e,i=await(n.isRTL==null?void 0:n.isRTL(o.floating)),l=ao(r),a=uu(r),s=cu(r)==="x",u=["left","top"].includes(l)?-1:1,c=i&&s?-1:1,f=typeof t=="function"?t(e):t;let{mainAxis:d,crossAxis:p,alignmentAxis:y}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:0,crossAxis:0,alignmentAxis:null,...f};return a&&typeof y=="number"&&(p=a==="end"?y*-1:y),s?{x:p*c,y:d*u}:{x:d*u,y:p*c}}const Qw=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){const{x:r,y:n}=t,o=await l3(t,e);return{x:r+o.x,y:n+o.y,data:o}}}};function a3(e){return e==="x"?"y":"x"}const Yd=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:r,y:n,placement:o}=t,{mainAxis:i=!0,crossAxis:l=!1,limiter:a={fn:v=>{let{x:m,y:h}=v;return{x:m,y:h}}},...s}=e,u={x:r,y:n},c=await Gd(t,s),f=cu(ao(o)),d=a3(f);let p=u[f],y=u[d];if(i){const v=f==="y"?"top":"left",m=f==="y"?"bottom":"right",h=p+c[v],_=p-c[m];p=Um(h,p,_)}if(l){const v=d==="y"?"top":"left",m=d==="y"?"bottom":"right",h=y+c[v],_=y-c[m];y=Um(h,y,_)}const w=a.fn({...t,[f]:p,[d]:y});return{...w,data:{x:w.x-r,y:w.y-n}}}}},s3=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){const{placement:r,rects:n,platform:o,elements:i}=t,{apply:l,...a}=e,s=await Gd(t,a),u=ao(r),c=uu(r);let f,d;u==="top"||u==="bottom"?(f=u,d=c===(await(o.isRTL==null?void 0:o.isRTL(i.floating))?"start":"end")?"left":"right"):(d=u,f=c==="end"?"top":"bottom");const p=Br(s.left,0),y=Br(s.right,0),w=Br(s.top,0),v=Br(s.bottom,0),m={availableHeight:n.floating.height-(["left","right"].includes(r)?2*(w!==0||v!==0?w+v:Br(s.top,s.bottom)):s[f]),availableWidth:n.floating.width-(["top","bottom"].includes(r)?2*(p!==0||y!==0?p+y:Br(s.left,s.right)):s[d])},h=await o.getDimensions(i.floating);l?.({...t,...m});const _=await o.getDimensions(i.floating);return h.width!==_.width||h.height!==_.height?{reset:{rects:!0}}:{}}}};function Zw(e){return e&&e.document&&e.location&&e.alert&&e.setInterval}function rr(e){if(e==null)return window;if(!Zw(e)){const t=e.ownerDocument;return t&&t.defaultView||window}return e}function Hi(e){return rr(e).getComputedStyle(e)}function Qt(e){return Zw(e)?"":e?(e.nodeName||"").toLowerCase():""}function Jw(){const e=navigator.userAgentData;return e!=null&&e.brands?e.brands.map(t=>t.brand+"/"+t.version).join(" "):navigator.userAgent}function Dt(e){return e instanceof rr(e).HTMLElement}function Rr(e){return e instanceof rr(e).Element}function u3(e){return e instanceof rr(e).Node}function Xd(e){if(typeof ShadowRoot>"u")return!1;const t=rr(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function fu(e){const{overflow:t,overflowX:r,overflowY:n}=Hi(e);return/auto|scroll|overlay|hidden/.test(t+n+r)}function c3(e){return["table","td","th"].includes(Qt(e))}function e_(e){const t=/firefox/i.test(Jw()),r=Hi(e);return r.transform!=="none"||r.perspective!=="none"||r.contain==="paint"||["transform","perspective"].includes(r.willChange)||t&&r.willChange==="filter"||t&&(r.filter?r.filter!=="none":!1)}function t_(){return!/^((?!chrome|android).)*safari/i.test(Jw())}const Ym=Math.min,oi=Math.max,Na=Math.round;function Zt(e,t,r){var n,o,i,l;t===void 0&&(t=!1),r===void 0&&(r=!1);const a=e.getBoundingClientRect();let s=1,u=1;t&&Dt(e)&&(s=e.offsetWidth>0&&Na(a.width)/e.offsetWidth||1,u=e.offsetHeight>0&&Na(a.height)/e.offsetHeight||1);const c=Rr(e)?rr(e):window,f=!t_()&&r,d=(a.left+(f&&(n=(o=c.visualViewport)==null?void 0:o.offsetLeft)!=null?n:0))/s,p=(a.top+(f&&(i=(l=c.visualViewport)==null?void 0:l.offsetTop)!=null?i:0))/u,y=a.width/s,w=a.height/u;return{width:y,height:w,top:p,right:d+y,bottom:p+w,left:d,x:d,y:p}}function Dr(e){return((u3(e)?e.ownerDocument:e.document)||window.document).documentElement}function du(e){return Rr(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.pageXOffset,scrollTop:e.pageYOffset}}function r_(e){return Zt(Dr(e)).left+du(e).scrollLeft}function f3(e){const t=Zt(e);return Na(t.width)!==e.offsetWidth||Na(t.height)!==e.offsetHeight}function d3(e,t,r){const n=Dt(t),o=Dr(t),i=Zt(e,n&&f3(t),r==="fixed");let l={scrollLeft:0,scrollTop:0};const a={x:0,y:0};if(n||!n&&r!=="fixed")if((Qt(t)!=="body"||fu(o))&&(l=du(t)),Dt(t)){const s=Zt(t,!0);a.x=s.x+t.clientLeft,a.y=s.y+t.clientTop}else o&&(a.x=r_(o));return{x:i.left+l.scrollLeft-a.x,y:i.top+l.scrollTop-a.y,width:i.width,height:i.height}}function n_(e){return Qt(e)==="html"?e:e.assignedSlot||e.parentNode||(Xd(e)?e.host:null)||Dr(e)}function Xm(e){return!Dt(e)||getComputedStyle(e).position==="fixed"?null:e.offsetParent}function p3(e){let t=n_(e);for(Xd(t)&&(t=t.host);Dt(t)&&!["html","body"].includes(Qt(t));){if(e_(t))return t;t=t.parentNode}return null}function vf(e){const t=rr(e);let r=Xm(e);for(;r&&c3(r)&&getComputedStyle(r).position==="static";)r=Xm(r);return r&&(Qt(r)==="html"||Qt(r)==="body"&&getComputedStyle(r).position==="static"&&!e_(r))?t:r||p3(e)||t}function qm(e){if(Dt(e))return{width:e.offsetWidth,height:e.offsetHeight};const t=Zt(e);return{width:t.width,height:t.height}}function g3(e){let{rect:t,offsetParent:r,strategy:n}=e;const o=Dt(r),i=Dr(r);if(r===i)return t;let l={scrollLeft:0,scrollTop:0};const a={x:0,y:0};if((o||!o&&n!=="fixed")&&((Qt(r)!=="body"||fu(i))&&(l=du(r)),Dt(r))){const s=Zt(r,!0);a.x=s.x+r.clientLeft,a.y=s.y+r.clientTop}return{...t,x:t.x-l.scrollLeft+a.x,y:t.y-l.scrollTop+a.y}}function m3(e,t){const r=rr(e),n=Dr(e),o=r.visualViewport;let i=n.clientWidth,l=n.clientHeight,a=0,s=0;if(o){i=o.width,l=o.height;const u=t_();(u||!u&&t==="fixed")&&(a=o.offsetLeft,s=o.offsetTop)}return{width:i,height:l,x:a,y:s}}function v3(e){var t;const r=Dr(e),n=du(e),o=(t=e.ownerDocument)==null?void 0:t.body,i=oi(r.scrollWidth,r.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),l=oi(r.scrollHeight,r.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0);let a=-n.scrollLeft+r_(e);const s=-n.scrollTop;return Hi(o||r).direction==="rtl"&&(a+=oi(r.clientWidth,o?o.clientWidth:0)-i),{width:i,height:l,x:a,y:s}}function o_(e){const t=n_(e);return["html","body","#document"].includes(Qt(t))?e.ownerDocument.body:Dt(t)&&fu(t)?t:o_(t)}function ln(e,t){var r;t===void 0&&(t=[]);const n=o_(e),o=n===((r=e.ownerDocument)==null?void 0:r.body),i=rr(n),l=o?[i].concat(i.visualViewport||[],fu(n)?n:[]):n,a=t.concat(l);return o?a:a.concat(ln(l))}function h3(e,t){const r=t.getRootNode==null?void 0:t.getRootNode();if(e.contains(t))return!0;if(r&&Xd(r)){let n=t;do{if(n&&e===n)return!0;n=n.parentNode||n.host}while(n)}return!1}function y3(e,t){const r=Zt(e,!1,t==="fixed"),n=r.top+e.clientTop,o=r.left+e.clientLeft;return{top:n,left:o,x:o,y:n,right:o+e.clientWidth,bottom:n+e.clientHeight,width:e.clientWidth,height:e.clientHeight}}function Km(e,t,r){return t==="viewport"?Ra(m3(e,r)):Rr(t)?y3(t,r):Ra(v3(Dr(e)))}function w3(e){const t=ln(e),n=["absolute","fixed"].includes(Hi(e).position)&&Dt(e)?vf(e):e;return Rr(n)?t.filter(o=>Rr(o)&&h3(o,n)&&Qt(o)!=="body"):[]}function _3(e){let{element:t,boundary:r,rootBoundary:n,strategy:o}=e;const l=[...r==="clippingAncestors"?w3(t):[].concat(r),n],a=l[0],s=l.reduce((u,c)=>{const f=Km(t,c,o);return u.top=oi(f.top,u.top),u.right=Ym(f.right,u.right),u.bottom=Ym(f.bottom,u.bottom),u.left=oi(f.left,u.left),u},Km(t,a,o));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}}const S3={getClippingRect:_3,convertOffsetParentRelativeRectToViewportRelativeRect:g3,isElement:Rr,getDimensions:qm,getOffsetParent:vf,getDocumentElement:Dr,getElementRects:e=>{let{reference:t,floating:r,strategy:n}=e;return{reference:d3(t,vf(r),n),floating:{...qm(r),x:0,y:0}}},getClientRects:e=>Array.from(e.getClientRects()),isRTL:e=>Hi(e).direction==="rtl"};function b3(e,t,r,n){n===void 0&&(n={});const{ancestorScroll:o=!0,ancestorResize:i=!0,elementResize:l=!0,animationFrame:a=!1}=n,s=o&&!a,u=i&&!a,c=s||u?[...Rr(e)?ln(e):[],...ln(t)]:[];c.forEach(w=>{s&&w.addEventListener("scroll",r,{passive:!0}),u&&w.addEventListener("resize",r)});let f=null;if(l){let w=!0;f=new ResizeObserver(()=>{w||r(),w=!1}),Rr(e)&&!a&&f.observe(e),f.observe(t)}let d,p=a?Zt(e):null;a&&y();function y(){const w=Zt(e);p&&(w.x!==p.x||w.y!==p.y||w.width!==p.width||w.height!==p.height)&&r(),p=w,d=requestAnimationFrame(y)}return r(),()=>{var w;c.forEach(v=>{s&&v.removeEventListener("scroll",r),u&&v.removeEventListener("resize",r)}),(w=f)==null||w.disconnect(),f=null,a&&cancelAnimationFrame(d)}}const x3=(e,t,r)=>Zk(e,t,{platform:S3,...r});var hf=typeof document<"u"?g.exports.useLayoutEffect:g.exports.useEffect;function yf(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let r,n,o;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!=t.length)return!1;for(n=r;n--!==0;)if(!yf(e[n],t[n]))return!1;return!0}if(o=Object.keys(e),r=o.length,r!==Object.keys(t).length)return!1;for(n=r;n--!==0;)if(!Object.prototype.hasOwnProperty.call(t,o[n]))return!1;for(n=r;n--!==0;){const i=o[n];if(!(i==="_owner"&&e.$$typeof)&&!yf(e[i],t[i]))return!1}return!0}return e!==e&&t!==t}function P3(e){const t=g.exports.useRef(e);return hf(()=>{t.current=e}),t}function $3(e){let{middleware:t,placement:r="bottom",strategy:n="absolute",whileElementsMounted:o}=e===void 0?{}:e;const i=g.exports.useRef(null),l=g.exports.useRef(null),a=P3(o),s=g.exports.useRef(null),[u,c]=g.exports.useState({x:null,y:null,strategy:n,placement:r,middlewareData:{}}),[f,d]=g.exports.useState(t);yf(f?.map(_=>{let{options:b}=_;return b}),t?.map(_=>{let{options:b}=_;return b}))||d(t);const p=g.exports.useCallback(()=>{!i.current||!l.current||x3(i.current,l.current,{middleware:f,placement:r,strategy:n}).then(_=>{y.current&&Ei.exports.flushSync(()=>{c(_)})})},[f,r,n]);hf(()=>{y.current&&p()},[p]);const y=g.exports.useRef(!1);hf(()=>(y.current=!0,()=>{y.current=!1}),[]);const w=g.exports.useCallback(()=>{if(typeof s.current=="function"&&(s.current(),s.current=null),i.current&&l.current)if(a.current){const _=a.current(i.current,l.current,p);s.current=_}else p()},[p,a]),v=g.exports.useCallback(_=>{i.current=_,w()},[w]),m=g.exports.useCallback(_=>{l.current=_,w()},[w]),h=g.exports.useMemo(()=>({reference:i,floating:l}),[]);return g.exports.useMemo(()=>({...u,update:p,refs:h,reference:v,floating:m}),[u,p,h,v,m])}var qn=typeof document<"u"?g.exports.useLayoutEffect:g.exports.useEffect;function O3(){const e=new Map;return{emit(t,r){var n;(n=e.get(t))==null||n.forEach(o=>o(r))},on(t,r){e.set(t,[...e.get(t)||[],r])},off(t,r){e.set(t,(e.get(t)||[]).filter(n=>n!==r))}}}let ec=!1,C3=0;const Qm=()=>"floating-ui-"+C3++;function E3(){const[e,t]=g.exports.useState(()=>ec?Qm():void 0);return qn(()=>{e==null&&t(Qm())},[]),g.exports.useEffect(()=>{ec||(ec=!0)},[]),e}const Zm=li["useId".toString()],Jm=Zm??E3,k3=g.exports.createContext(null),R3=g.exports.createContext(null),I3=()=>{var e,t;return(e=(t=g.exports.useContext(k3))==null?void 0:t.id)!=null?e:null},qd=()=>g.exports.useContext(R3);function Ut(e){var t;return(t=e?.ownerDocument)!=null?t:document}function i_(e){var t;return(t=Ut(e).defaultView)!=null?t:window}function za(e){return e?e instanceof i_(e).Element:!1}function l_(e){return e?e instanceof i_(e).HTMLElement:!1}function Kd(e){let{open:t=!1,onOpenChange:r=()=>{},whileElementsMounted:n,placement:o,middleware:i,strategy:l,nodeId:a}=e===void 0?{}:e;const s=qd(),u=g.exports.useRef(null),c=g.exports.useRef({}),f=g.exports.useState(()=>O3())[0],d=$3({placement:o,middleware:i,strategy:l,whileElementsMounted:n}),p=g.exports.useMemo(()=>({...d.refs,domReference:u}),[d.refs]),y=g.exports.useMemo(()=>({...d,refs:p,dataRef:c,nodeId:a,events:f,open:t,onOpenChange:r}),[d,a,f,t,r,p]);qn(()=>{const m=s?.nodesRef.current.find(h=>h.id===a);m&&(m.context=y)});const{reference:w}=d,v=g.exports.useCallback(m=>{(za(m)||m===null)&&(y.refs.domReference.current=m),w(m)},[w,y.refs]);return g.exports.useMemo(()=>({...d,context:y,refs:p,reference:v}),[d,p,y,v])}function tc(e,t,r){const n=new Map;return{...r==="floating"&&{tabIndex:-1},...e,...t.map(o=>o?o[r]:null).concat(e).reduce((o,i)=>(i&&Object.entries(i).forEach(l=>{let[a,s]=l;if(a.indexOf("on")===0){if(n.has(a)||n.set(a,[]),typeof s=="function"){var u;(u=n.get(a))==null||u.push(s)}o[a]=function(){for(var c,f=arguments.length,d=new Array(f),p=0;py(...d))}}else o[a]=s}),o),{})}}const N3=function(e){return e===void 0&&(e=[]),{getReferenceProps:t=>tc(t,e,"reference"),getFloatingProps:t=>tc(t,e,"floating"),getItemProps:t=>tc(t,e,"item")}};function z3(e,t){var r;let n=(r=e.filter(l=>{var a;return l.parentId===t&&((a=l.context)==null?void 0:a.open)}))!=null?r:[],o=n;for(;o.length;){var i;o=(i=e.filter(l=>{var a;return(a=o)==null?void 0:a.some(s=>{var u;return l.parentId===s.id&&((u=l.context)==null?void 0:u.open)})}))!=null?i:[],n=n.concat(o)}return n}function a_(e){let t=e.activeElement;for(;((r=t)==null||(n=r.shadowRoot)==null?void 0:n.activeElement)!=null;){var r,n;t=t.shadowRoot.activeElement}return t}function Da(e){const t=g.exports.useRef(e);return qn(()=>{t.current=e}),t}function D3(e){const t=g.exports.useRef();return qn(()=>{t.current=e},[e]),t.current}function Vl(e,t,r){return r&&r!=="mouse"?0:typeof e=="number"?e:e?.[t]}const T3=function(e,t){let{enabled:r=!0,delay:n=0,handleClose:o=null,mouseOnly:i=!1,restMs:l=0}=t===void 0?{}:t;const{open:a,onOpenChange:s,dataRef:u,events:c,refs:f}=e,d=qd(),p=I3(),y=Da(s),w=Da(o),v=D3(a),m=g.exports.useRef(),h=g.exports.useRef(),_=g.exports.useRef(),b=g.exports.useRef(),O=g.exports.useRef(!0),x=g.exports.useRef(!1);g.exports.useEffect(()=>{if(!r)return;function z(){clearTimeout(h.current),clearTimeout(b.current),O.current=!0}return c.on("dismiss",z),()=>{c.off("dismiss",z)}},[r,c,f]),g.exports.useEffect(()=>{if(!r||!w.current)return;function z(){var j;(j=u.current.openEvent)!=null&&j.type.includes("mouse")&&y.current(!1)}const D=Ut(f.floating.current).documentElement;return D.addEventListener("mouseleave",z),()=>{D.removeEventListener("mouseleave",z)}},[f,y,r,w,u]);const P=g.exports.useCallback(function(z){z===void 0&&(z=!0);const D=Vl(n,"close",m.current);D&&!_.current?(clearTimeout(h.current),h.current=setTimeout(()=>y.current(!1),D)):z&&(clearTimeout(h.current),y.current(!1))},[n,y]),$=g.exports.useCallback(()=>{_.current&&(Ut(f.floating.current).removeEventListener("pointermove",_.current),_.current=void 0)},[f]),C=g.exports.useCallback(()=>{Ut(f.floating.current).body.style.pointerEvents="",x.current=!1},[f]);if(g.exports.useEffect(()=>{if(!r)return;function z(W){if(clearTimeout(h.current),O.current=!1,a||i&&m.current!=="mouse"||l>0&&Vl(n,"open")===0)return;u.current.openEvent=W;const re=Vl(n,"open",m.current);re?h.current=setTimeout(()=>{y.current(!0)},re):y.current(!0)}function D(W){var re,se;if(((re=u.current.openEvent)==null?void 0:re.type)==="click"||((se=u.current.openEvent)==null?void 0:se.type)==="pointerdown")return;const ie=Ut(f.floating.current);if(clearTimeout(b.current),w.current){clearTimeout(h.current),_.current&&ie.removeEventListener("pointermove",_.current),_.current=w.current({...e,tree:d,x:W.clientX,y:W.clientY,onClose(){$(),P()}}),ie.addEventListener("pointermove",_.current);return}P()}function j(W){w.current==null||w.current({...e,tree:d,x:W.clientX,y:W.clientY,leave:!0,onClose(){$(),P()}})(W)}const B=f.floating.current,V=f.domReference.current;if(za(V))return a&&V.addEventListener("mouseleave",j),B?.addEventListener("mouseleave",j),V.addEventListener("mousemove",z,{once:!0}),V.addEventListener("mouseenter",z),V.addEventListener("mouseleave",D),()=>{a&&V.removeEventListener("mouseleave",j),B?.removeEventListener("mouseleave",j),V.removeEventListener("mousemove",z),V.removeEventListener("mouseenter",z),V.removeEventListener("mouseleave",D)}},[r,P,e,n,w,u,i,y,a,d,l,$,f]),qn(()=>{if(!!r&&a&&w.current){Ut(f.floating.current).body.style.pointerEvents="none",x.current=!0;const j=f.domReference.current,B=f.floating.current;if(l_(j)&&B){var z,D;const V=d==null||(z=d.nodesRef.current.find(W=>W.id===p))==null||(D=z.context)==null?void 0:D.refs.floating.current;return V&&(V.style.pointerEvents=""),j.style.pointerEvents="auto",B.style.pointerEvents="auto",()=>{j.style.pointerEvents="",B.style.pointerEvents=""}}}},[r,a,p,f,d,w,u]),qn(()=>{v&&!a&&(m.current=void 0,$(),C())}),g.exports.useEffect(()=>()=>{$(),clearTimeout(h.current),clearTimeout(b.current),x.current&&C()},[$,C]),!r)return{};function I(z){m.current=z.pointerType}return{reference:{onPointerDown:I,onPointerEnter:I,onMouseMove(){a||l===0||(clearTimeout(b.current),b.current=setTimeout(()=>{O.current||s(!0)},l))}},floating:{onMouseEnter(){clearTimeout(h.current)},onMouseLeave(){P(!1)}}}},s_=g.exports.createContext({delay:1e3,initialDelay:1e3,currentId:null,setCurrentId:()=>{},setState:()=>{}}),u_=()=>g.exports.useContext(s_),M3=e=>{let{children:t,delay:r}=e;const[n,o]=g.exports.useState({delay:r,initialDelay:r,currentId:null}),i=g.exports.useCallback(l=>{o(a=>({...a,currentId:l}))},[]);return g.exports.createElement(s_.Provider,{value:g.exports.useMemo(()=>({...n,setState:o,setCurrentId:i}),[n,o,i])},t)},j3=(e,t)=>{let{open:r,onOpenChange:n}=e,{id:o}=t;const{currentId:i,initialDelay:l,setState:a}=u_(),s=Da(n);g.exports.useEffect(()=>{i&&s.current&&(a(u=>({...u,delay:{open:1,close:Vl(l,"close")}})),i!==o&&s.current(!1))},[o,s,a,i,l]),g.exports.useEffect(()=>{!r&&i===o&&s.current&&(s.current(!1),a(u=>({...u,delay:l,currentId:null})))},[r,a,i,o,s,l])},L3=function(e,t){let{open:r}=e,{enabled:n=!0,role:o="dialog"}=t===void 0?{}:t;const i=Jm(),l=Jm(),a={id:i,role:o};return n?o==="tooltip"?{reference:{"aria-describedby":r?i:void 0},floating:a}:{reference:{"aria-expanded":r?"true":"false","aria-haspopup":o,"aria-controls":r?i:void 0,...o==="listbox"&&{role:"combobox"},...o==="menu"&&{id:l}},floating:{...a,...o==="menu"&&{"aria-labelledby":l}}}:{}};function rc(e,t){if(t==null)return!1;if("composedPath"in e)return e.composedPath().includes(t);const r=e;return r.target!=null&&t.contains(r.target)}const F3=function(e,t){let{open:r,onOpenChange:n,refs:o,events:i,nodeId:l}=e,{enabled:a=!0,escapeKey:s=!0,outsidePointerDown:u=!0,referencePointerDown:c=!1,ancestorScroll:f=!1,bubbles:d=!0}=t===void 0?{}:t;const p=qd(),y=Da(n),w=g.exports.useCallback(()=>{var v;return(v=o.floating.current)==null?void 0:v.contains(a_(Ut(o.floating.current)))},[o]);return g.exports.useEffect(()=>{if(!r||!a)return;function v(O){if(O.key==="Escape"){if(!d&&!w())return;i.emit("dismiss"),y.current(!1),l_(o.domReference.current)&&o.domReference.current.focus()}}function m(O){const x=p&&z3(p.nodesRef.current,l).some(P=>{var $;return rc(O,($=P.context)==null?void 0:$.refs.floating.current)});rc(O,o.floating.current)||rc(O,o.domReference.current)||x||!d&&!w()||(i.emit("dismiss"),y.current(!1))}function h(){y.current(!1)}const _=Ut(o.floating.current);s&&_.addEventListener("keydown",v),u&&_.addEventListener("mousedown",m);const b=(f?[...za(o.reference.current)?ln(o.reference.current):[],...za(o.floating.current)?ln(o.floating.current):[]]:[]).filter(O=>{var x;return O!==((x=_.defaultView)==null?void 0:x.visualViewport)});return b.forEach(O=>O.addEventListener("scroll",h,{passive:!0})),()=>{s&&_.removeEventListener("keydown",v),u&&_.removeEventListener("mousedown",m),b.forEach(O=>O.removeEventListener("scroll",h))}},[s,u,i,p,l,r,y,f,a,d,w,o]),a?{reference:{onPointerDown(){c&&(i.emit("dismiss"),n(!1))}}}:{}},A3=function(e,t){let{open:r,onOpenChange:n,dataRef:o,refs:i,events:l}=e,{enabled:a=!0,keyboardOnly:s=!0}=t===void 0?{}:t;const u=g.exports.useRef(""),c=g.exports.useRef(!1);return g.exports.useEffect(()=>{var f;if(!a)return;const d=Ut(i.floating.current),p=(f=d.defaultView)!=null?f:window;function y(){u.current&&i.domReference.current===a_(d)&&(c.current=!r)}function w(){setTimeout(()=>{c.current=!1,u.current=""})}return p.addEventListener("focus",w),p.addEventListener("blur",y),()=>{p.removeEventListener("focus",w),p.removeEventListener("blur",y)}},[i,r,a]),g.exports.useEffect(()=>{if(!a)return;function f(){c.current=!0}return l.on("dismiss",f),()=>{l.off("dismiss",f)}},[l,a]),a?{reference:{onPointerDown(f){let{pointerType:d}=f;u.current=d,c.current=!!(d&&s)},onFocus(f){var d,p,y;c.current||f.type==="focus"&&((d=o.current.openEvent)==null?void 0:d.type)==="mousedown"&&(p=i.domReference.current)!=null&&p.contains((y=o.current.openEvent)==null?void 0:y.target)||(o.current.openEvent=f.nativeEvent,n(!0))},onBlur(f){var d,p;const y=f.relatedTarget;(d=i.floating.current)!=null&&d.contains(y)||(p=i.domReference.current)!=null&&p.contains(y)||(c.current=!1,n(!1))}}}:{}};function c_({opened:e,floating:t,positionDependencies:r}){const[n,o]=g.exports.useState(0);g.exports.useEffect(()=>{if(t.refs.reference.current&&t.refs.floating.current)return b3(t.refs.reference.current,t.refs.floating.current,t.update)},[t.refs.reference,t.refs.floating,e,n]),kr(()=>{t.update()},r),kr(()=>{o(i=>i+1)},[e])}function V3(e){const t=[Qw(e.offset)];return e.middlewares.shift&&t.push(Yd()),e.middlewares.flip&&t.push(Kw()),t}function H3(e){const[t,r]=Li({value:e.opened,defaultValue:e.defaultOpened,finalValue:!1,onChange:e.onChange}),n=()=>{var l;(l=e.onClose)==null||l.call(e),r(!1)},o=()=>{var l,a;t?((l=e.onClose)==null||l.call(e),r(!1)):((a=e.onOpen)==null||a.call(e),r(!0))},i=Kd({placement:e.position,middleware:[...V3(e),...e.width==="target"?[s3({apply({rects:l}){var a,s;Object.assign((s=(a=i.refs.floating.current)==null?void 0:a.style)!=null?s:{},{width:`${l.reference.width}px`})}})]:[]]});return c_({opened:e.opened,positionDependencies:e.positionDependencies,floating:i}),kr(()=>{var l;(l=e.onPositionChange)==null||l.call(e,i.placement)},[i.placement]),{floating:i,controlled:typeof e.opened=="boolean",opened:t,onClose:n,onToggle:o}}const f_={context:"Popover component was not found in the tree",children:"Popover.Target component children should be an element or a component that accepts ref, fragments, strings, numbers and other primitive values are not supported"},[B3,d_]=Id(f_.context);var W3=Object.defineProperty,U3=Object.defineProperties,G3=Object.getOwnPropertyDescriptors,Ta=Object.getOwnPropertySymbols,p_=Object.prototype.hasOwnProperty,g_=Object.prototype.propertyIsEnumerable,ev=(e,t,r)=>t in e?W3(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,hl=(e,t)=>{for(var r in t||(t={}))p_.call(t,r)&&ev(e,r,t[r]);if(Ta)for(var r of Ta(t))g_.call(t,r)&&ev(e,r,t[r]);return e},Y3=(e,t)=>U3(e,G3(t)),X3=(e,t)=>{var r={};for(var n in e)p_.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Ta)for(var n of Ta(e))t.indexOf(n)<0&&g_.call(e,n)&&(r[n]=e[n]);return r};const m_=g.exports.forwardRef((e,t)=>{var r=e,{children:n,refProp:o="ref",popupType:i="dialog"}=r,l=X3(r,["children","refProp","popupType"]);if(!Ti(n))throw new Error(f_.children);const a=l,s=d_(),u=pn(s.reference,n.ref,t),c=s.withRoles?{"aria-haspopup":i,"aria-expanded":s.opened,"aria-controls":s.getDropdownId(),id:s.getTargetId()}:{};return g.exports.cloneElement(n,hl(Y3(hl(hl(hl({},a),c),s.targetProps),{className:y1(s.targetProps.className,a.className,n.props.className),[o]:u}),s.controlled?null:{onClick:s.onToggle}))});m_.displayName="@mantine/core/PopoverTarget";var q3=Q((e,{radius:t,shadow:r})=>({dropdown:{position:"absolute",backgroundColor:e.white,background:e.colorScheme==="dark"?e.colors.dark[6]:e.white,border:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2]}`,padding:`${e.spacing.sm}px ${e.spacing.md}px`,boxShadow:e.shadows[r]||r||"none",borderRadius:e.fn.radius(t),"&:focus":{outline:0}},arrow:{backgroundColor:"inherit",border:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2]}`,zIndex:1}})),K3=q3,Q3=Object.defineProperty,tv=Object.getOwnPropertySymbols,Z3=Object.prototype.hasOwnProperty,J3=Object.prototype.propertyIsEnumerable,rv=(e,t,r)=>t in e?Q3(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,wn=(e,t)=>{for(var r in t||(t={}))Z3.call(t,r)&&rv(e,r,t[r]);if(tv)for(var r of tv(t))J3.call(t,r)&&rv(e,r,t[r]);return e};const nv={entering:"in",entered:"in",exiting:"out",exited:"out","pre-exiting":"out","pre-entering":"out"};function v_({transition:e,state:t,duration:r,timingFunction:n}){const o={transitionDuration:`${r}ms`,transitionTimingFunction:n};return typeof e=="string"?e in fl?wn(wn(wn({transitionProperty:fl[e].transitionProperty},o),fl[e].common),fl[e][nv[t]]):null:wn(wn(wn({transitionProperty:e.transitionProperty},o),e.common),e[nv[t]])}function h_({duration:e,exitDuration:t,timingFunction:r,mounted:n,onEnter:o,onExit:i,onEntered:l,onExited:a}){const s=at(),u=K1(),c=s.respectReducedMotion?u:!1,[f,d]=g.exports.useState(n?"entered":"exited");let p=c?0:e;const y=g.exports.useRef(-1),w=v=>{const m=v?o:i,h=v?l:a;if(d(v?"pre-entering":"pre-exiting"),window.clearTimeout(y.current),p=c?0:v?e:t,p===0)typeof m=="function"&&m(),typeof h=="function"&&h(),d(v?"entered":"exited");else{const _=window.setTimeout(()=>{typeof m=="function"&&m(),d(v?"entering":"exiting")},10);y.current=window.setTimeout(()=>{window.clearTimeout(_),typeof h=="function"&&h(),d(v?"entered":"exited")},p)}};return kr(()=>{w(n)},[n]),g.exports.useEffect(()=>()=>window.clearTimeout(y.current),[]),{transitionDuration:p,transitionStatus:f,transitionTimingFunction:r||s.transitionTimingFunction}}function pu({transition:e,duration:t=250,exitDuration:r=t,mounted:n,children:o,timingFunction:i,onExit:l,onEntered:a,onEnter:s,onExited:u}){const{transitionDuration:c,transitionStatus:f,transitionTimingFunction:d}=h_({mounted:n,exitDuration:r,duration:t,timingFunction:i,onExit:l,onEntered:a,onEnter:s,onExited:u});return c===0?n?E.createElement(E.Fragment,null,o({})):null:f==="exited"?null:E.createElement(E.Fragment,null,o(v_({transition:e,duration:c,state:f,timingFunction:d})))}pu.displayName="@mantine/core/Transition";function y_({children:e,active:t=!0,refProp:r="ref"}){const n=X1(t),o=pn(n,e?.ref);return Ti(e)?g.exports.cloneElement(e,{[r]:o}):e}y_.displayName="@mantine/core/FocusTrap";var e5=Object.defineProperty,t5=Object.defineProperties,r5=Object.getOwnPropertyDescriptors,ov=Object.getOwnPropertySymbols,n5=Object.prototype.hasOwnProperty,o5=Object.prototype.propertyIsEnumerable,iv=(e,t,r)=>t in e?e5(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,lr=(e,t)=>{for(var r in t||(t={}))n5.call(t,r)&&iv(e,r,t[r]);if(ov)for(var r of ov(t))o5.call(t,r)&&iv(e,r,t[r]);return e},yl=(e,t)=>t5(e,r5(t));function lv(e,t,r){return e==="center"?{top:`calc(50% - ${t/2}px)`}:e==="end"?{bottom:r}:e==="start"?{top:r}:{}}function av(e,t,r,n){return e==="center"?{left:`calc(50% - ${t/2}px)`}:e==="end"?{[n==="ltr"?"right":"left"]:r}:e==="start"?{[n==="ltr"?"left":"right"]:r}:{}}function i5({position:e,withBorder:t,arrowSize:r,arrowOffset:n,dir:o}){const[i,l="center"]=e.split("-"),a={width:r,height:r,transform:"rotate(45deg)",position:"absolute"},s=t?-r/2-1:-r/2;return i==="left"?yl(lr(lr({},a),lv(l,r,n)),{[o==="ltr"?"right":"left"]:s,[o==="ltr"?"borderLeft":"borderRight"]:0,borderBottom:0}):i==="right"?yl(lr(lr({},a),lv(l,r,n)),{[o==="ltr"?"left":"right"]:s,[o==="ltr"?"borderRight":"borderLeft"]:0,borderTop:0}):i==="top"?yl(lr(lr({},a),av(l,r,n,o)),{bottom:s,borderTop:0,[o==="ltr"?"borderLeft":"borderRight"]:0}):i==="bottom"?yl(lr(lr({},a),av(l,r,n,o)),{top:s,borderBottom:0,[o==="ltr"?"borderRight":"borderLeft"]:0}):{}}var l5=Object.defineProperty,a5=Object.defineProperties,s5=Object.getOwnPropertyDescriptors,Ma=Object.getOwnPropertySymbols,w_=Object.prototype.hasOwnProperty,__=Object.prototype.propertyIsEnumerable,sv=(e,t,r)=>t in e?l5(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,u5=(e,t)=>{for(var r in t||(t={}))w_.call(t,r)&&sv(e,r,t[r]);if(Ma)for(var r of Ma(t))__.call(t,r)&&sv(e,r,t[r]);return e},c5=(e,t)=>a5(e,s5(t)),f5=(e,t)=>{var r={};for(var n in e)w_.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Ma)for(var n of Ma(e))t.indexOf(n)<0&&__.call(e,n)&&(r[n]=e[n]);return r};function Qd(e){var t=e,{withBorder:r,position:n,arrowSize:o,arrowOffset:i,visible:l}=t,a=f5(t,["withBorder","position","arrowSize","arrowOffset","visible"]);const s=at();return l?E.createElement("div",c5(u5({},a),{style:i5({withBorder:r,position:n,arrowSize:o,arrowOffset:i,dir:s.dir})})):null}Qd.displayName="@mantine/core/FloatingArrow";var d5=Object.defineProperty,p5=Object.defineProperties,g5=Object.getOwnPropertyDescriptors,ja=Object.getOwnPropertySymbols,S_=Object.prototype.hasOwnProperty,b_=Object.prototype.propertyIsEnumerable,uv=(e,t,r)=>t in e?d5(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,wl=(e,t)=>{for(var r in t||(t={}))S_.call(t,r)&&uv(e,r,t[r]);if(ja)for(var r of ja(t))b_.call(t,r)&&uv(e,r,t[r]);return e},cv=(e,t)=>p5(e,g5(t)),m5=(e,t)=>{var r={};for(var n in e)S_.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&ja)for(var n of ja(e))t.indexOf(n)<0&&b_.call(e,n)&&(r[n]=e[n]);return r};function x_(e){var t=e,{style:r,className:n,children:o}=t,i=m5(t,["style","className","children"]);const{classNames:l,styles:a,unstyled:s,staticSelector:u}=dn(),c=d_(),{classes:f,cx:d}=K3({radius:c.radius,shadow:c.shadow},{name:u,classNames:l,styles:a,unstyled:s}),p=W1({opened:c.opened,shouldReturnFocus:!1}),y=c.withRoles?{"aria-labelledby":c.getTargetId(),id:c.getDropdownId(),role:"dialog"}:{};return E.createElement(Fi,{withinPortal:c.withinPortal},E.createElement(pu,{mounted:c.opened,transition:c.transition,duration:c.transitionDuration,exitDuration:typeof c.exitTransitionDuration=="number"?c.exitTransitionDuration:c.transitionDuration},w=>{var v,m;return E.createElement(y_,{active:c.trapFocus},E.createElement(q,wl(cv(wl({},y),{tabIndex:-1,ref:c.floating,style:cv(wl(wl({},r),w),{zIndex:c.zIndex,top:(v=c.y)!=null?v:"",left:(m=c.x)!=null?m:"",width:c.width==="target"?void 0:c.width}),className:d(f.dropdown,n),onKeyDownCapture:I$(c.onClose,{active:c.closeOnEscape,onTrigger:p}),"data-position":c.placement}),i),o,E.createElement(Qd,{visible:c.withArrow,withBorder:!0,position:c.placement,arrowSize:c.arrowSize,arrowOffset:c.arrowOffset,className:f.arrow})))}))}x_.displayName="@mantine/core/PopoverDropdown";function P_(e,t){if(e==="rtl"&&(t.includes("right")||t.includes("left"))){const[r,n]=t.split("-"),o=r==="right"?"left":"right";return n===void 0?o:`${o}-${n}`}return t}var fv=Object.getOwnPropertySymbols,v5=Object.prototype.hasOwnProperty,h5=Object.prototype.propertyIsEnumerable,y5=(e,t)=>{var r={};for(var n in e)v5.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&fv)for(var n of fv(e))t.indexOf(n)<0&&h5.call(e,n)&&(r[n]=e[n]);return r};const w5={position:"bottom",offset:8,positionDependencies:[],transition:"fade",transitionDuration:150,middlewares:{flip:!0,shift:!0},arrowSize:7,arrowOffset:5,closeOnClickOutside:!0,withinPortal:!1,closeOnEscape:!0,trapFocus:!1,withRoles:!0,clickOutsideEvents:["mousedown","touchstart"],zIndex:io("popover"),__staticSelector:"Popover"};function nr(e){const t=ee("Popover",w5,e),{children:r,position:n,offset:o,onPositionChange:i,positionDependencies:l,opened:a,transition:s,transitionDuration:u,width:c,middlewares:f,withArrow:d,arrowSize:p,arrowOffset:y,unstyled:w,classNames:v,styles:m,closeOnClickOutside:h,withinPortal:_,closeOnEscape:b,clickOutsideEvents:O,trapFocus:x,onClose:P,onOpen:$,onChange:C,zIndex:I,radius:z,shadow:D,id:j,defaultOpened:B,exitTransitionDuration:V,__staticSelector:W,withRoles:re}=t,se=y5(t,["children","position","offset","onPositionChange","positionDependencies","opened","transition","transitionDuration","width","middlewares","withArrow","arrowSize","arrowOffset","unstyled","classNames","styles","closeOnClickOutside","withinPortal","closeOnEscape","clickOutsideEvents","trapFocus","onClose","onOpen","onChange","zIndex","radius","shadow","id","defaultOpened","exitTransitionDuration","__staticSelector","withRoles"]),ie=lo(j),Ne=at(),R=H3({middlewares:f,width:c,position:P_(Ne.dir,n),offset:o+(d?p/2:0),onPositionChange:i,positionDependencies:l,opened:a,defaultOpened:B,onChange:C,onOpen:$,onClose:P});return XC(()=>h&&R.onClose(),O,[R.floating.refs.floating.current,R.floating.refs.reference.current]),E.createElement(V1,{classNames:v,styles:m,unstyled:w,staticSelector:W},E.createElement(B3,{value:{controlled:R.controlled,reference:R.floating.reference,floating:R.floating.floating,x:R.floating.x,y:R.floating.y,opened:R.opened,transition:s,transitionDuration:u,exitTransitionDuration:V,width:c,withArrow:d,arrowSize:p,arrowOffset:y,placement:R.floating.placement,trapFocus:x,withinPortal:_,zIndex:I,radius:z,shadow:D,closeOnEscape:b,onClose:R.onClose,onToggle:R.onToggle,getTargetId:()=>`${ie}-target`,getDropdownId:()=>`${ie}-dropdown`,withRoles:re,targetProps:se}},r))}nr.Target=m_;nr.Dropdown=x_;nr.displayName="@mantine/core/Popover";var _5=Object.defineProperty,La=Object.getOwnPropertySymbols,$_=Object.prototype.hasOwnProperty,O_=Object.prototype.propertyIsEnumerable,dv=(e,t,r)=>t in e?_5(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,S5=(e,t)=>{for(var r in t||(t={}))$_.call(t,r)&&dv(e,r,t[r]);if(La)for(var r of La(t))O_.call(t,r)&&dv(e,r,t[r]);return e},b5=(e,t)=>{var r={};for(var n in e)$_.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&La)for(var n of La(e))t.indexOf(n)<0&&O_.call(e,n)&&(r[n]=e[n]);return r};function x5(e){var t=e,{children:r,component:n="div",maxHeight:o=220,direction:i="column",id:l,innerRef:a}=t,s=b5(t,["children","component","maxHeight","direction","id","innerRef"]);return E.createElement(nr.Dropdown,S5({p:0,onMouseDown:u=>u.preventDefault()},s),E.createElement("div",{style:{maxHeight:o,display:"flex"}},E.createElement(q,{component:n||"div",id:`${l}-items`,"aria-labelledby":`${l}-label`,role:"listbox",onMouseDown:u=>u.preventDefault(),style:{flex:1,overflowY:n!==Ud?"auto":void 0},"data-combobox-popover":!0,ref:a},E.createElement("div",{style:{display:"flex",flexDirection:i,width:"100%",padding:4}},r))))}function ii({opened:e,transition:t="fade",transitionDuration:r=0,shadow:n,withinPortal:o,children:i,__staticSelector:l,onDirectionChange:a,switchDirectionOnFlip:s,zIndex:u,dropdownPosition:c,positionDependencies:f=[],classNames:d,styles:p,unstyled:y}){return E.createElement(nr,{unstyled:y,classNames:d,styles:p,width:"target",withRoles:!1,opened:e,middlewares:{flip:c==="flip",shift:!1},position:c==="flip"?"bottom":c,positionDependencies:f,zIndex:u,__staticSelector:l,withinPortal:o,transition:t,transitionDuration:r,shadow:n,onPositionChange:w=>s&&a?.(w==="top"?"column-reverse":"column")},i)}ii.Target=nr.Target;ii.Dropdown=x5;var P5=Object.defineProperty,$5=Object.defineProperties,O5=Object.getOwnPropertyDescriptors,Fa=Object.getOwnPropertySymbols,C_=Object.prototype.hasOwnProperty,E_=Object.prototype.propertyIsEnumerable,pv=(e,t,r)=>t in e?P5(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,nc=(e,t)=>{for(var r in t||(t={}))C_.call(t,r)&&pv(e,r,t[r]);if(Fa)for(var r of Fa(t))E_.call(t,r)&&pv(e,r,t[r]);return e},C5=(e,t)=>$5(e,O5(t)),E5=(e,t)=>{var r={};for(var n in e)C_.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Fa)for(var n of Fa(e))t.indexOf(n)<0&&E_.call(e,n)&&(r[n]=e[n]);return r};function k_(e,t,r){const n=ee(e,t,r),{label:o,description:i,error:l,required:a,classNames:s,styles:u,className:c,unstyled:f,__staticSelector:d,sx:p,errorProps:y,labelProps:w,descriptionProps:v,wrapperProps:m,id:h,size:_,style:b,inputContainer:O,inputWrapperOrder:x}=n,P=E5(n,["label","description","error","required","classNames","styles","className","unstyled","__staticSelector","sx","errorProps","labelProps","descriptionProps","wrapperProps","id","size","style","inputContainer","inputWrapperOrder"]),$=lo(h),{systemStyles:C,rest:I}=nu(P);return C5(nc({},I),{classNames:s,styles:u,unstyled:f,wrapperProps:nc(nc({label:o,description:i,error:l,required:a,classNames:s,className:c,__staticSelector:d,sx:p,errorProps:y,labelProps:w,descriptionProps:v,unstyled:f,styles:u,id:$,size:_,style:b,inputContainer:O,inputWrapperOrder:x},m),C),inputProps:{required:a,classNames:s,styles:u,unstyled:f,id:$,size:_,__staticSelector:d,invalid:!!l}})}var k5=Q((e,{size:t})=>({label:{display:"inline-block",fontSize:e.fn.size({size:t,sizes:e.fontSizes}),fontWeight:500,color:e.colorScheme==="dark"?e.colors.dark[0]:e.colors.gray[9],wordBreak:"break-word",cursor:"default",WebkitTapHighlightColor:"transparent"},required:{color:e.fn.variant({variant:"filled",color:"red"}).background}})),R5=k5,I5=Object.defineProperty,Aa=Object.getOwnPropertySymbols,R_=Object.prototype.hasOwnProperty,I_=Object.prototype.propertyIsEnumerable,gv=(e,t,r)=>t in e?I5(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,N5=(e,t)=>{for(var r in t||(t={}))R_.call(t,r)&&gv(e,r,t[r]);if(Aa)for(var r of Aa(t))I_.call(t,r)&&gv(e,r,t[r]);return e},z5=(e,t)=>{var r={};for(var n in e)R_.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Aa)for(var n of Aa(e))t.indexOf(n)<0&&I_.call(e,n)&&(r[n]=e[n]);return r};const Zd=g.exports.forwardRef((e,t)=>{var r=e,{labelElement:n="label",children:o,required:i,size:l="sm",classNames:a,styles:s,unstyled:u,className:c,htmlFor:f,__staticSelector:d}=r,p=z5(r,["labelElement","children","required","size","classNames","styles","unstyled","className","htmlFor","__staticSelector"]);const{classes:y,cx:w}=R5({size:l},{name:["InputWrapper",d],classNames:a,styles:s,unstyled:u});return U(q,{...N5({component:n,ref:t,className:w(y.label,c),htmlFor:n==="label"?f:void 0},p),children:[o,i&&S("span",{className:y.required,"aria-hidden":!0,children:" *"})]})});Zd.displayName="@mantine/core/InputLabel";var D5=Q((e,{size:t})=>({error:{wordBreak:"break-word",color:e.fn.variant({variant:"filled",color:"red"}).background,fontSize:e.fn.size({size:t,sizes:e.fontSizes})-2,lineHeight:1.2,display:"block"}})),T5=D5,M5=Object.defineProperty,Va=Object.getOwnPropertySymbols,N_=Object.prototype.hasOwnProperty,z_=Object.prototype.propertyIsEnumerable,mv=(e,t,r)=>t in e?M5(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,j5=(e,t)=>{for(var r in t||(t={}))N_.call(t,r)&&mv(e,r,t[r]);if(Va)for(var r of Va(t))z_.call(t,r)&&mv(e,r,t[r]);return e},L5=(e,t)=>{var r={};for(var n in e)N_.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Va)for(var n of Va(e))t.indexOf(n)<0&&z_.call(e,n)&&(r[n]=e[n]);return r};const Jd=g.exports.forwardRef((e,t)=>{var r=e,{children:n,className:o,classNames:i,styles:l,unstyled:a,size:s="sm",__staticSelector:u}=r,c=L5(r,["children","className","classNames","styles","unstyled","size","__staticSelector"]);const{classes:f,cx:d}=T5({size:s},{name:["InputWrapper",u],classNames:i,styles:l,unstyled:a});return S(mt,{...j5({className:d(f.error,o),ref:t,role:"alert"},c),children:n})});Jd.displayName="@mantine/core/InputError";var F5=Q((e,{size:t})=>({description:{wordBreak:"break-word",color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6],fontSize:e.fn.size({size:t,sizes:e.fontSizes})-2,lineHeight:1.2,display:"block"}})),A5=F5,V5=Object.defineProperty,Ha=Object.getOwnPropertySymbols,D_=Object.prototype.hasOwnProperty,T_=Object.prototype.propertyIsEnumerable,vv=(e,t,r)=>t in e?V5(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,H5=(e,t)=>{for(var r in t||(t={}))D_.call(t,r)&&vv(e,r,t[r]);if(Ha)for(var r of Ha(t))T_.call(t,r)&&vv(e,r,t[r]);return e},B5=(e,t)=>{var r={};for(var n in e)D_.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Ha)for(var n of Ha(e))t.indexOf(n)<0&&T_.call(e,n)&&(r[n]=e[n]);return r};const ep=g.exports.forwardRef((e,t)=>{var r=e,{children:n,className:o,classNames:i,styles:l,unstyled:a,size:s="sm",__staticSelector:u}=r,c=B5(r,["children","className","classNames","styles","unstyled","size","__staticSelector"]);const{classes:f,cx:d}=A5({size:s},{name:["InputWrapper",u],classNames:i,styles:l,unstyled:a});return S(mt,{...H5({color:"dimmed",className:d(f.description,o),ref:t,unstyled:a},c),children:n})});ep.displayName="@mantine/core/InputDescription";const M_=g.exports.createContext({offsetBottom:!1,offsetTop:!1}),W5=M_.Provider,U5=()=>g.exports.useContext(M_);function G5(e,{hasDescription:t,hasError:r}){const n=e.findIndex(s=>s==="input"),o=e[n-1],i=e[n+1];return{offsetBottom:t&&i==="description"||r&&i==="error",offsetTop:t&&o==="description"||r&&o==="error"}}var Y5=Object.defineProperty,X5=Object.defineProperties,q5=Object.getOwnPropertyDescriptors,hv=Object.getOwnPropertySymbols,K5=Object.prototype.hasOwnProperty,Q5=Object.prototype.propertyIsEnumerable,yv=(e,t,r)=>t in e?Y5(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Z5=(e,t)=>{for(var r in t||(t={}))K5.call(t,r)&&yv(e,r,t[r]);if(hv)for(var r of hv(t))Q5.call(t,r)&&yv(e,r,t[r]);return e},J5=(e,t)=>X5(e,q5(t)),eR=Q(e=>({root:J5(Z5({},e.fn.fontStyles()),{lineHeight:e.lineHeight})})),tR=eR,rR=Object.defineProperty,nR=Object.defineProperties,oR=Object.getOwnPropertyDescriptors,Ba=Object.getOwnPropertySymbols,j_=Object.prototype.hasOwnProperty,L_=Object.prototype.propertyIsEnumerable,wv=(e,t,r)=>t in e?rR(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Vr=(e,t)=>{for(var r in t||(t={}))j_.call(t,r)&&wv(e,r,t[r]);if(Ba)for(var r of Ba(t))L_.call(t,r)&&wv(e,r,t[r]);return e},iR=(e,t)=>nR(e,oR(t)),lR=(e,t)=>{var r={};for(var n in e)j_.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Ba)for(var n of Ba(e))t.indexOf(n)<0&&L_.call(e,n)&&(r[n]=e[n]);return r};const aR={labelElement:"label",size:"sm",inputContainer:e=>e,inputWrapperOrder:["label","description","input","error"]},F_=g.exports.forwardRef((e,t)=>{const r=ee("InputWrapper",aR,e),{className:n,label:o,children:i,required:l,id:a,error:s,description:u,labelElement:c,labelProps:f,descriptionProps:d,errorProps:p,classNames:y,styles:w,size:v,inputContainer:m,__staticSelector:h,unstyled:_,inputWrapperOrder:b}=r,O=lR(r,["className","label","children","required","id","error","description","labelElement","labelProps","descriptionProps","errorProps","classNames","styles","size","inputContainer","__staticSelector","unstyled","inputWrapperOrder"]),{classes:x,cx:P}=tR(null,{classNames:y,styles:w,name:["InputWrapper",h],unstyled:_}),$={classNames:y,styles:w,unstyled:_,size:v,__staticSelector:h},C=o&&S(Zd,{...Vr(Vr({key:"label",labelElement:c,id:a?`${a}-label`:void 0,htmlFor:a,required:l},$),f),children:o}),I=u&&S(ep,{...Vr(Vr({key:"description"},$),d),children:u}),z=S(it,{children:m(i)}),D=typeof s!="boolean"&&s&&S(Jd,{...Vr(iR(Vr({},p),{key:"error"}),$),children:s}),j=b.map(B=>{switch(B){case"label":return C;case"input":return z;case"description":return I;case"error":return D;default:return null}});return S(W5,{value:G5(b,{hasDescription:!!I,hasError:!!D}),children:S(q,{...Vr({className:P(x.root,n),ref:t},O),children:j})})});F_.displayName="@mantine/core/InputWrapper";var sR=Object.defineProperty,uR=Object.defineProperties,cR=Object.getOwnPropertyDescriptors,_v=Object.getOwnPropertySymbols,fR=Object.prototype.hasOwnProperty,dR=Object.prototype.propertyIsEnumerable,Sv=(e,t,r)=>t in e?sR(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,oc=(e,t)=>{for(var r in t||(t={}))fR.call(t,r)&&Sv(e,r,t[r]);if(_v)for(var r of _v(t))dR.call(t,r)&&Sv(e,r,t[r]);return e},bv=(e,t)=>uR(e,cR(t));const ut={xs:30,sm:36,md:42,lg:50,xl:60};function pR({theme:e,variant:t}){return t==="default"?{border:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4]}`,backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.white,transition:"border-color 100ms ease","&:focus, &:focus-within":{outline:"none",borderColor:e.colors[e.primaryColor][e.fn.primaryShade()]}}:t==="filled"?{border:"1px solid transparent",backgroundColor:e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[1],"&:focus, &:focus-within":{outline:"none",borderColor:`${e.colors[e.primaryColor][e.fn.primaryShade()]} !important`}}:{borderWidth:0,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,backgroundColor:"transparent",minHeight:28,outline:0,"&:focus, &:focus-within":{outline:"none",borderColor:"transparent"},"&:disabled":{backgroundColor:"transparent","&:focus, &:focus-within":{outline:"none",borderColor:"transparent"}}}}var gR=Q((e,{size:t,multiline:r,radius:n,variant:o,invalid:i,rightSectionWidth:l,withRightSection:a,iconWidth:s,offsetBottom:u,offsetTop:c,pointer:f})=>{const d=e.fn.variant({variant:"filled",color:"red"}).background,p=o==="default"||o==="filled"?{minHeight:e.fn.size({size:t,sizes:ut}),paddingLeft:e.fn.size({size:t,sizes:ut})/3,paddingRight:a?l:e.fn.size({size:t,sizes:ut})/3,borderRadius:e.fn.radius(n)}:null;return{wrapper:{position:"relative",marginTop:c?e.spacing.xs/2:void 0,marginBottom:u?e.spacing.xs/2:void 0},input:oc(bv(oc(bv(oc({},e.fn.fontStyles()),{height:r?o==="unstyled"?void 0:"auto":e.fn.size({size:t,sizes:ut}),WebkitTapHighlightColor:"transparent",lineHeight:r?e.lineHeight:`${e.fn.size({size:t,sizes:ut})-2}px`,appearance:"none",resize:"none",boxSizing:"border-box",fontSize:e.fn.size({size:t,sizes:e.fontSizes}),width:"100%",color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,display:"block",textAlign:"left",cursor:f?"pointer":void 0}),p),{"&:disabled":{backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[1],color:e.colors.dark[2],opacity:.6,cursor:"not-allowed","&::placeholder":{color:e.colors.dark[2]}},"&::placeholder":{opacity:1,userSelect:"none",color:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[5]},"&::-webkit-inner-spin-button, &::-webkit-outer-spin-button, &::-webkit-search-decoration, &::-webkit-search-cancel-button, &::-webkit-search-results-button, &::-webkit-search-results-decoration":{appearance:"none"},"&[type=number]":{MozAppearance:"textfield"}}),pR({theme:e,variant:o})),withIcon:{paddingLeft:typeof s=="number"?s:e.fn.size({size:t,sizes:ut})},invalid:{color:d,borderColor:d,"&::placeholder":{opacity:1,color:d}},disabled:{backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[1],color:e.colors.dark[2],opacity:.6,cursor:"not-allowed","&::placeholder":{color:e.colors.dark[2]}},icon:{pointerEvents:"none",position:"absolute",zIndex:1,left:0,top:0,bottom:0,display:"flex",alignItems:"center",justifyContent:"center",width:typeof s=="number"?s:e.fn.size({size:t,sizes:ut}),color:i?e.colors.red[e.colorScheme==="dark"?6:7]:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[5]},rightSection:{position:"absolute",top:0,bottom:0,right:0,display:"flex",alignItems:"center",justifyContent:"center",width:l}}}),mR=gR,vR=Object.defineProperty,hR=Object.defineProperties,yR=Object.getOwnPropertyDescriptors,Wa=Object.getOwnPropertySymbols,A_=Object.prototype.hasOwnProperty,V_=Object.prototype.propertyIsEnumerable,xv=(e,t,r)=>t in e?vR(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,_l=(e,t)=>{for(var r in t||(t={}))A_.call(t,r)&&xv(e,r,t[r]);if(Wa)for(var r of Wa(t))V_.call(t,r)&&xv(e,r,t[r]);return e},Pv=(e,t)=>hR(e,yR(t)),wR=(e,t)=>{var r={};for(var n in e)A_.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Wa)for(var n of Wa(e))t.indexOf(n)<0&&V_.call(e,n)&&(r[n]=e[n]);return r};const _R={rightSectionWidth:36,size:"sm",variant:"default"},so=g.exports.forwardRef((e,t)=>{const r=ee("Input",_R,e),{className:n,invalid:o,required:i,disabled:l,variant:a,icon:s,style:u,rightSectionWidth:c,iconWidth:f,rightSection:d,rightSectionProps:p,radius:y,size:w,wrapperProps:v,classNames:m,styles:h,__staticSelector:_,multiline:b,sx:O,unstyled:x,pointer:P}=r,$=wR(r,["className","invalid","required","disabled","variant","icon","style","rightSectionWidth","iconWidth","rightSection","rightSectionProps","radius","size","wrapperProps","classNames","styles","__staticSelector","multiline","sx","unstyled","pointer"]),{offsetBottom:C,offsetTop:I}=U5(),{classes:z,cx:D}=mR({radius:y,size:w,multiline:b,variant:a,invalid:o,rightSectionWidth:c,iconWidth:f,withRightSection:!!d,offsetBottom:C,offsetTop:I,pointer:P},{classNames:m,styles:h,name:["Input",_],unstyled:x}),{systemStyles:j,rest:B}=nu($);return U(q,{..._l(_l({className:D(z.wrapper,n),sx:O,style:u},j),v),children:[s&&S("div",{className:z.icon,children:s}),S(q,{...Pv(_l({component:"input"},B),{ref:t,required:i,"aria-invalid":o,disabled:l,className:D(z[`${a}Variant`],z.input,{[z.withIcon]:s,[z.invalid]:o,[z.disabled]:l})})}),d&&S("div",{...Pv(_l({},p),{className:z.rightSection}),children:d})]})});so.displayName="@mantine/core/Input";so.Wrapper=F_;so.Label=Zd;so.Description=ep;so.Error=Jd;const Ua=so;var SR=Q((e,{orientation:t,buttonBorderWidth:r})=>({root:{display:"flex",flexDirection:t==="vertical"?"column":"row","& [data-button]":{"&:first-of-type":{borderBottomRightRadius:0,[t==="vertical"?"borderBottomLeftRadius":"borderTopRightRadius"]:0,[t==="vertical"?"borderBottomWidth":"borderRightWidth"]:r/2},"&:last-of-type":{borderTopLeftRadius:0,[t==="vertical"?"borderTopRightRadius":"borderBottomLeftRadius"]:0,[t==="vertical"?"borderTopWidth":"borderLeftWidth"]:r/2},"&:not(:first-of-type):not(:last-of-type)":{borderRadius:0,[t==="vertical"?"borderTopWidth":"borderLeftWidth"]:r/2,[t==="vertical"?"borderBottomWidth":"borderRightWidth"]:r/2},"& + [data-button]":{[t==="vertical"?"marginTop":"marginLeft"]:-r,"@media (min-resolution: 192dpi)":{[t==="vertical"?"marginTop":"marginLeft"]:0}}}}})),bR=SR,xR=Object.defineProperty,Ga=Object.getOwnPropertySymbols,H_=Object.prototype.hasOwnProperty,B_=Object.prototype.propertyIsEnumerable,$v=(e,t,r)=>t in e?xR(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,PR=(e,t)=>{for(var r in t||(t={}))H_.call(t,r)&&$v(e,r,t[r]);if(Ga)for(var r of Ga(t))B_.call(t,r)&&$v(e,r,t[r]);return e},$R=(e,t)=>{var r={};for(var n in e)H_.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Ga)for(var n of Ga(e))t.indexOf(n)<0&&B_.call(e,n)&&(r[n]=e[n]);return r};const OR={orientation:"horizontal",buttonBorderWidth:1},W_=g.exports.forwardRef((e,t)=>{const r=ee("ButtonGroup",OR,e),{className:n,orientation:o,buttonBorderWidth:i,unstyled:l}=r,a=$R(r,["className","orientation","buttonBorderWidth","unstyled"]),{classes:s,cx:u}=bR({orientation:o,buttonBorderWidth:i},{name:"ButtonGroup",unstyled:l});return S(q,{...PR({className:u(s.root,n),ref:t},a)})});W_.displayName="@mantine/core/ButtonGroup";var CR=Object.defineProperty,ER=Object.defineProperties,kR=Object.getOwnPropertyDescriptors,Ov=Object.getOwnPropertySymbols,RR=Object.prototype.hasOwnProperty,IR=Object.prototype.propertyIsEnumerable,Cv=(e,t,r)=>t in e?CR(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Gr=(e,t)=>{for(var r in t||(t={}))RR.call(t,r)&&Cv(e,r,t[r]);if(Ov)for(var r of Ov(t))IR.call(t,r)&&Cv(e,r,t[r]);return e},wf=(e,t)=>ER(e,kR(t));const _f={xs:{height:ut.xs,paddingLeft:14,paddingRight:14},sm:{height:ut.sm,paddingLeft:18,paddingRight:18},md:{height:ut.md,paddingLeft:22,paddingRight:22},lg:{height:ut.lg,paddingLeft:26,paddingRight:26},xl:{height:ut.xl,paddingLeft:32,paddingRight:32},"compact-xs":{height:22,paddingLeft:7,paddingRight:7},"compact-sm":{height:26,paddingLeft:8,paddingRight:8},"compact-md":{height:30,paddingLeft:10,paddingRight:10},"compact-lg":{height:34,paddingLeft:12,paddingRight:12},"compact-xl":{height:40,paddingLeft:14,paddingRight:14}};function NR({compact:e,size:t,withLeftIcon:r,withRightIcon:n}){if(e)return _f[`compact-${t}`];const o=_f[t];return wf(Gr({},o),{paddingLeft:r?o.paddingLeft/1.5:o.paddingLeft,paddingRight:n?o.paddingRight/1.5:o.paddingRight})}const zR=e=>({display:e?"block":"inline-block",width:e?"100%":"auto"});function DR({variant:e,theme:t,color:r,gradient:n}){const o=t.fn.variant({color:r,variant:e,gradient:n});return e==="gradient"?{border:0,backgroundImage:o.background,color:o.color,"&:hover":t.fn.hover({backgroundSize:"200%"})}:Gr({border:`1px solid ${o.border}`,backgroundColor:o.background,color:o.color},t.fn.hover({backgroundColor:o.hover}))}var TR=Q((e,{color:t,size:r,radius:n,fullWidth:o,compact:i,gradient:l,variant:a,withLeftIcon:s,withRightIcon:u})=>({root:wf(Gr(wf(Gr(Gr(Gr(Gr({},NR({compact:i,size:r,withLeftIcon:s,withRightIcon:u})),e.fn.fontStyles()),e.fn.focusStyles()),zR(o)),{borderRadius:e.fn.radius(n),fontWeight:600,position:"relative",lineHeight:1,fontSize:e.fn.size({size:r,sizes:e.fontSizes}),userSelect:"none",cursor:"pointer"}),DR({variant:a,theme:e,color:t,gradient:l})),{"&:active":e.activeStyles,"&[data-disabled]":{borderColor:"transparent",backgroundColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2],color:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[5],cursor:"not-allowed","&:active":{transform:"none"}},"&[data-loading]":{pointerEvents:"none","&::before":{content:'""',position:"absolute",top:-1,left:-1,right:-1,bottom:-1,backgroundColor:e.colorScheme==="dark"?e.fn.rgba(e.colors.dark[7],.5):"rgba(255, 255, 255, .5)",borderRadius:e.fn.radius(n),cursor:"not-allowed"}}}),icon:{display:"flex",alignItems:"center"},leftIcon:{marginRight:10},rightIcon:{marginLeft:10},inner:{display:"flex",alignItems:"center",justifyContent:"center",height:"100%",overflow:"visible"},label:{whiteSpace:"nowrap",height:"100%",overflow:"hidden",display:"flex",alignItems:"center"}})),MR=TR,jR=Object.defineProperty,Ya=Object.getOwnPropertySymbols,U_=Object.prototype.hasOwnProperty,G_=Object.prototype.propertyIsEnumerable,Ev=(e,t,r)=>t in e?jR(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,kv=(e,t)=>{for(var r in t||(t={}))U_.call(t,r)&&Ev(e,r,t[r]);if(Ya)for(var r of Ya(t))G_.call(t,r)&&Ev(e,r,t[r]);return e},LR=(e,t)=>{var r={};for(var n in e)U_.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Ya)for(var n of Ya(e))t.indexOf(n)<0&&G_.call(e,n)&&(r[n]=e[n]);return r};const FR={size:"sm",type:"button",variant:"filled",loaderPosition:"left"},tp=g.exports.forwardRef((e,t)=>{const r=ee("Button",FR,e),{className:n,size:o,color:i,type:l,disabled:a,children:s,leftIcon:u,rightIcon:c,fullWidth:f,variant:d,radius:p,uppercase:y,compact:w,loading:v,loaderPosition:m,loaderProps:h,gradient:_,classNames:b,styles:O,unstyled:x}=r,P=LR(r,["className","size","color","type","disabled","children","leftIcon","rightIcon","fullWidth","variant","radius","uppercase","compact","loading","loaderPosition","loaderProps","gradient","classNames","styles","unstyled"]),{classes:$,cx:C,theme:I}=MR({radius:p,color:i,size:o,fullWidth:f,compact:w,gradient:_,variant:d,withLeftIcon:!!u,withRightIcon:!!c},{name:"Button",unstyled:x,classNames:b,styles:O}),z=I.fn.variant({color:i,variant:d}),D=S(Bd,{...kv({color:z.color,size:I.fn.size({size:o,sizes:_f}).height/2},h)});return S(ou,{...kv({className:C($.root,n),type:l,disabled:a||v,"data-button":!0,"data-disabled":a||void 0,"data-loading":v||void 0,ref:t,unstyled:x},P),children:U("div",{className:$.inner,children:[(u||v&&m==="left")&&S("span",{className:C($.icon,$.leftIcon),children:v&&m==="left"?D:u}),S("span",{className:$.label,style:{textTransform:y?"uppercase":void 0},children:s}),(c||v&&m==="right")&&S("span",{className:C($.icon,$.rightIcon),children:v&&m==="right"?D:c})]})})});tp.displayName="@mantine/core/Button";tp.Group=W_;const Kn=tp;var AR=Q((e,{radius:t,shadow:r,withBorder:n})=>({root:{outline:0,WebkitTapHighlightColor:"transparent",display:"block",textDecoration:"none",color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,backgroundColor:e.colorScheme==="dark"?e.colors.dark[7]:e.white,boxSizing:"border-box",borderRadius:e.fn.radius(t),boxShadow:e.shadows[r]||r||"none",border:n?`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3]}`:void 0}})),VR=AR,HR=Object.defineProperty,Xa=Object.getOwnPropertySymbols,Y_=Object.prototype.hasOwnProperty,X_=Object.prototype.propertyIsEnumerable,Rv=(e,t,r)=>t in e?HR(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,BR=(e,t)=>{for(var r in t||(t={}))Y_.call(t,r)&&Rv(e,r,t[r]);if(Xa)for(var r of Xa(t))X_.call(t,r)&&Rv(e,r,t[r]);return e},WR=(e,t)=>{var r={};for(var n in e)Y_.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Xa)for(var n of Xa(e))t.indexOf(n)<0&&X_.call(e,n)&&(r[n]=e[n]);return r};const UR={},q_=g.exports.forwardRef((e,t)=>{const r=ee("Paper",UR,e),{className:n,children:o,radius:i,withBorder:l,shadow:a,unstyled:s}=r,u=WR(r,["className","children","radius","withBorder","shadow","unstyled"]),{classes:c,cx:f}=VR({radius:i,shadow:a,withBorder:l},{name:"Paper",unstyled:s});return S(q,{...BR({className:f(c.root,n),ref:t},u),children:o})});q_.displayName="@mantine/core/Paper";const GR=q_;var YR=Object.defineProperty,qa=Object.getOwnPropertySymbols,K_=Object.prototype.hasOwnProperty,Q_=Object.prototype.propertyIsEnumerable,Iv=(e,t,r)=>t in e?YR(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,XR=(e,t)=>{for(var r in t||(t={}))K_.call(t,r)&&Iv(e,r,t[r]);if(qa)for(var r of qa(t))Q_.call(t,r)&&Iv(e,r,t[r]);return e},qR=(e,t)=>{var r={};for(var n in e)K_.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&qa)for(var n of qa(e))t.indexOf(n)<0&&Q_.call(e,n)&&(r[n]=e[n]);return r};const Z_=g.exports.forwardRef((e,t)=>{const r=ee("Center",{},e),{inline:n,sx:o}=r,i=qR(r,["inline","sx"]);return S(q,{...XR({ref:t,sx:[{display:n?"inline-flex":"flex",alignItems:"center",justifyContent:"center"},...Si(o)]},i)})});Z_.displayName="@mantine/core/Center";const J_=Z_;function KR(e){return g.exports.Children.toArray(e).filter(Boolean)}const eS={left:"flex-start",center:"center",right:"flex-end",apart:"space-between"};var QR=Q((e,{spacing:t,position:r,noWrap:n,grow:o,align:i,count:l})=>({root:{boxSizing:"border-box",display:"flex",flexDirection:"row",alignItems:i||"center",flexWrap:n?"nowrap":"wrap",justifyContent:eS[r],gap:e.fn.size({size:t,sizes:e.spacing})},child:{boxSizing:"border-box",maxWidth:o?`calc(${100/l}% - ${e.fn.size({size:t,sizes:e.spacing})-e.fn.size({size:t,sizes:e.spacing})/l}px)`:void 0,flexGrow:o?1:0}})),ZR=QR,JR=Object.defineProperty,Ka=Object.getOwnPropertySymbols,tS=Object.prototype.hasOwnProperty,rS=Object.prototype.propertyIsEnumerable,Nv=(e,t,r)=>t in e?JR(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,e4=(e,t)=>{for(var r in t||(t={}))tS.call(t,r)&&Nv(e,r,t[r]);if(Ka)for(var r of Ka(t))rS.call(t,r)&&Nv(e,r,t[r]);return e},t4=(e,t)=>{var r={};for(var n in e)tS.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Ka)for(var n of Ka(e))t.indexOf(n)<0&&rS.call(e,n)&&(r[n]=e[n]);return r};const r4={position:"left",spacing:"md"},jt=g.exports.forwardRef((e,t)=>{const r=ee("Group",r4,e),{className:n,position:o,align:i,children:l,noWrap:a,grow:s,spacing:u,unstyled:c}=r,f=t4(r,["className","position","align","children","noWrap","grow","spacing","unstyled"]),d=KR(l),{classes:p,cx:y}=ZR({align:i,grow:s,noWrap:a,spacing:u,position:o,count:d.length},{unstyled:c,name:"Group"}),w=d.map(v=>{var m;return typeof v=="object"&&v!==null&&"props"in v?E.cloneElement(v,{className:y(p.child,(m=v.props)==null?void 0:m.className)}):v});return S(q,{...e4({className:y(p.root,n),ref:t},f),children:w})});jt.displayName="@mantine/core/Group";var n4=Q((e,{spacing:t,align:r,justify:n})=>({root:{display:"flex",flexDirection:"column",alignItems:r,justifyContent:n,gap:e.fn.size({size:t,sizes:e.spacing})}})),o4=n4,i4=Object.defineProperty,Qa=Object.getOwnPropertySymbols,nS=Object.prototype.hasOwnProperty,oS=Object.prototype.propertyIsEnumerable,zv=(e,t,r)=>t in e?i4(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,l4=(e,t)=>{for(var r in t||(t={}))nS.call(t,r)&&zv(e,r,t[r]);if(Qa)for(var r of Qa(t))oS.call(t,r)&&zv(e,r,t[r]);return e},a4=(e,t)=>{var r={};for(var n in e)nS.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Qa)for(var n of Qa(e))t.indexOf(n)<0&&oS.call(e,n)&&(r[n]=e[n]);return r};const s4={spacing:"md",align:"stretch",justify:"top"},Tt=g.exports.forwardRef((e,t)=>{const r=ee("Stack",s4,e),{spacing:n,className:o,align:i,justify:l,unstyled:a}=r,s=a4(r,["spacing","className","align","justify","unstyled"]),{classes:u,cx:c}=o4({spacing:n,align:i,justify:l},{name:"Stack",unstyled:a});return S(q,{...l4({className:c(u.root,o),ref:t},s)})});Tt.displayName="@mantine/core/Stack";function iS({transitions:e,duration:t=250,exitDuration:r=t,mounted:n,children:o,timingFunction:i,onExit:l,onEntered:a,onEnter:s,onExited:u}){const{transitionDuration:c,transitionStatus:f,transitionTimingFunction:d}=h_({mounted:n,duration:t,exitDuration:r,timingFunction:i,onExit:l,onEntered:a,onEnter:s,onExited:u});if(c===0)return n?E.createElement(E.Fragment,null,o({})):null;if(f==="exited")return null;const p=Object.keys(e).reduce((y,w)=>(y[w]=v_({duration:e[w].duration,transition:e[w].transition,timingFunction:e[w].timingFunction||d,state:f}),y),{});return E.createElement(E.Fragment,null,o(p))}iS.displayName="@mantine/core/GroupedTransition";var u4=Q((e,{zIndex:t})=>({root:{position:"absolute",top:0,bottom:0,left:0,right:0,zIndex:t}})),c4=u4,f4=Object.defineProperty,d4=Object.defineProperties,p4=Object.getOwnPropertyDescriptors,Za=Object.getOwnPropertySymbols,lS=Object.prototype.hasOwnProperty,aS=Object.prototype.propertyIsEnumerable,Dv=(e,t,r)=>t in e?f4(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,ic=(e,t)=>{for(var r in t||(t={}))lS.call(t,r)&&Dv(e,r,t[r]);if(Za)for(var r of Za(t))aS.call(t,r)&&Dv(e,r,t[r]);return e},g4=(e,t)=>d4(e,p4(t)),m4=(e,t)=>{var r={};for(var n in e)lS.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Za)for(var n of Za(e))t.indexOf(n)<0&&aS.call(e,n)&&(r[n]=e[n]);return r};const v4={opacity:.6,color:"#fff",zIndex:io("modal"),radius:0,blur:0},sS=g.exports.forwardRef((e,t)=>{const r=ee("Overlay",v4,e),{opacity:n,blur:o,color:i,gradient:l,zIndex:a,radius:s,sx:u,unstyled:c,className:f}=r,d=m4(r,["opacity","blur","color","gradient","zIndex","radius","sx","unstyled","className"]),{classes:p,cx:y}=c4({zIndex:a},{name:"Overlay",unstyled:c}),w=l?{backgroundImage:l}:{backgroundColor:i},v=m=>S(q,{...ic({ref:t,className:y(p.root,f),sx:[h=>g4(ic({},w),{opacity:n,borderRadius:h.fn.size({size:s,sizes:h.radius})}),...Si(u)]},m)});return o?S(q,{...ic({className:y(p.root,f),sx:[{backdropFilter:`blur(${o}px)`},...Si(u)]},d),children:v()}):v(d)});sS.displayName="@mantine/core/Overlay";const h4=sS,uS=g.exports.createContext(null),y4=uS.Provider,w4=()=>g.exports.useContext(uS);var _4=Object.defineProperty,Tv=Object.getOwnPropertySymbols,S4=Object.prototype.hasOwnProperty,b4=Object.prototype.propertyIsEnumerable,Mv=(e,t,r)=>t in e?_4(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,x4=(e,t)=>{for(var r in t||(t={}))S4.call(t,r)&&Mv(e,r,t[r]);if(Tv)for(var r of Tv(t))b4.call(t,r)&&Mv(e,r,t[r]);return e};const Ja=(e,t)=>`${100/(t/e)}%`,cS=(e,t)=>e?`${100/(t/e)}%`:void 0;function P4({sizes:e,offsets:t,theme:r,columns:n,grow:o}){return aO.reduce((i,l)=>(typeof e[l]=="number"&&(i[`@media (min-width: ${r.breakpoints[l]+1}px)`]={flexBasis:Ja(e[l],n),flexShrink:0,maxWidth:o?"unset":Ja(e[l],n),marginLeft:cS(t[l],n)}),i),{})}var $4=Q((e,{gutter:t,grow:r,offset:n,offsetXs:o,offsetSm:i,offsetMd:l,offsetLg:a,offsetXl:s,columns:u,span:c,xs:f,sm:d,md:p,lg:y,xl:w})=>({root:x4({boxSizing:"border-box",flexGrow:r?1:0,padding:e.fn.size({size:t,sizes:e.spacing})/2,marginLeft:cS(n,u),flexBasis:Ja(c,u),flexShrink:0,maxWidth:r?"unset":Ja(c,u)},P4({sizes:{xs:f,sm:d,md:p,lg:y,xl:w},offsets:{xs:o,sm:i,md:l,lg:a,xl:s},theme:e,columns:u,grow:r}))})),O4=$4,C4=Object.defineProperty,es=Object.getOwnPropertySymbols,fS=Object.prototype.hasOwnProperty,dS=Object.prototype.propertyIsEnumerable,jv=(e,t,r)=>t in e?C4(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,E4=(e,t)=>{for(var r in t||(t={}))fS.call(t,r)&&jv(e,r,t[r]);if(es)for(var r of es(t))dS.call(t,r)&&jv(e,r,t[r]);return e},k4=(e,t)=>{var r={};for(var n in e)fS.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&es)for(var n of es(e))t.indexOf(n)<0&&dS.call(e,n)&&(r[n]=e[n]);return r};const R4={offset:0,offsetXs:0,offsetSm:0,offsetMd:0,offsetLg:0,offsetXl:0};function I4(e){return typeof e=="number"&&e>0&&e%1===0}const pS=g.exports.forwardRef((e,t)=>{const r=ee("Grid.Col",R4,e),{children:n,span:o,offset:i,offsetXs:l,offsetSm:a,offsetMd:s,offsetLg:u,offsetXl:c,xs:f,sm:d,md:p,lg:y,xl:w,className:v,id:m,unstyled:h}=r,_=k4(r,["children","span","offset","offsetXs","offsetSm","offsetMd","offsetLg","offsetXl","xs","sm","md","lg","xl","className","id","unstyled"]),b=w4();if(!b)throw new Error("[@mantine/core] Grid.Col was used outside of Grid context");const O=o||b.columns,{classes:x,cx:P}=O4({gutter:b.gutter,offset:i,offsetXs:l,offsetSm:a,offsetMd:s,offsetLg:u,offsetXl:c,xs:f,sm:d,md:p,lg:y,xl:w,grow:b.grow,columns:b.columns,span:O},{unstyled:h,name:"Col"});return!I4(O)||O>b.columns?null:S(q,{...E4({className:P(x.root,v),ref:t},_),children:n})});pS.displayName="@mantine/core/Col";var N4=Q((e,{justify:t,align:r,gutter:n})=>({root:{margin:-e.fn.size({size:n,sizes:e.spacing})/2,display:"flex",flexWrap:"wrap",justifyContent:t,alignItems:r}})),z4=N4,D4=Object.defineProperty,ts=Object.getOwnPropertySymbols,gS=Object.prototype.hasOwnProperty,mS=Object.prototype.propertyIsEnumerable,Lv=(e,t,r)=>t in e?D4(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,T4=(e,t)=>{for(var r in t||(t={}))gS.call(t,r)&&Lv(e,r,t[r]);if(ts)for(var r of ts(t))mS.call(t,r)&&Lv(e,r,t[r]);return e},M4=(e,t)=>{var r={};for(var n in e)gS.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&ts)for(var n of ts(e))t.indexOf(n)<0&&mS.call(e,n)&&(r[n]=e[n]);return r};const j4={gutter:"md",justify:"flex-start",align:"stretch",columns:12},gu=g.exports.forwardRef((e,t)=>{const r=ee("Grid",j4,e),{gutter:n,children:o,grow:i,justify:l,align:a,columns:s,className:u,id:c,unstyled:f}=r,d=M4(r,["gutter","children","grow","justify","align","columns","className","id","unstyled"]),{classes:p,cx:y}=z4({gutter:n,justify:l,align:a},{unstyled:f,name:"Grid"});return S(y4,{value:{gutter:n,grow:i,columns:s},children:S(q,{...T4({className:y(p.root,u),ref:t},d),children:o})})});gu.Col=pS;gu.displayName="@mantine/core/Grid";function L4({open:e,close:t,openDelay:r,closeDelay:n}){const o=g.exports.useRef(-1),i=g.exports.useRef(-1),l=()=>{window.clearTimeout(o.current),window.clearTimeout(i.current)},a=()=>{l(),r===0?e():o.current=window.setTimeout(e,r)},s=()=>{l(),n===0?t():i.current=window.setTimeout(t,n)};return g.exports.useEffect(()=>l,[]),{openDropdown:a,closeDropdown:s}}var F4=Q(e=>({divider:{margin:`${e.spacing.xs/2}px -5px`,borderTop:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2]}`}})),A4=F4,V4=Object.defineProperty,rs=Object.getOwnPropertySymbols,vS=Object.prototype.hasOwnProperty,hS=Object.prototype.propertyIsEnumerable,Fv=(e,t,r)=>t in e?V4(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,H4=(e,t)=>{for(var r in t||(t={}))vS.call(t,r)&&Fv(e,r,t[r]);if(rs)for(var r of rs(t))hS.call(t,r)&&Fv(e,r,t[r]);return e},B4=(e,t)=>{var r={};for(var n in e)vS.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&rs)for(var n of rs(e))t.indexOf(n)<0&&hS.call(e,n)&&(r[n]=e[n]);return r};function yS(e){var t=e,{children:r,className:n}=t,o=B4(t,["children","className"]);const{classNames:i,styles:l,unstyled:a}=dn(),{classes:s,cx:u}=A4(null,{name:"Menu",classNames:i,styles:l,unstyled:a});return E.createElement(q,H4({className:u(s.divider,n)},o))}yS.displayName="@mantine/core/MenuDivider";const wS={context:"Menu component was not found in the tree",children:"Menu.Target component children should be an element or a component that accepts ref, fragments, strings, numbers and other primitive values are not supported"},[W4,rp]=Id(wS.context);var U4=Object.defineProperty,ns=Object.getOwnPropertySymbols,_S=Object.prototype.hasOwnProperty,SS=Object.prototype.propertyIsEnumerable,Av=(e,t,r)=>t in e?U4(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,G4=(e,t)=>{for(var r in t||(t={}))_S.call(t,r)&&Av(e,r,t[r]);if(ns)for(var r of ns(t))SS.call(t,r)&&Av(e,r,t[r]);return e},Y4=(e,t)=>{var r={};for(var n in e)_S.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&ns)for(var n of ns(e))t.indexOf(n)<0&&SS.call(e,n)&&(r[n]=e[n]);return r};function bS(e){var t=e,{children:r,onMouseEnter:n,onMouseLeave:o}=t,i=Y4(t,["children","onMouseEnter","onMouseLeave"]);const l=g.exports.useRef(),a=rp(),s=f=>{(f.key==="ArrowUp"||f.key==="ArrowDown")&&(f.preventDefault(),l.current.querySelectorAll("[data-menu-item]")[0].focus())},u=Xt(n,()=>a.trigger==="hover"&&a.openDropdown()),c=Xt(o,()=>a.trigger==="hover"&&a.closeDropdown());return S(nr.Dropdown,{...G4({onMouseEnter:u,onMouseLeave:c,role:"menu","aria-orientation":"vertical"},i),children:S("div",{tabIndex:-1,"data-menu-dropdown":!0,"data-autofocus":!0,onKeyDown:s,ref:l,style:{outline:0},children:r})})}bS.displayName="@mantine/core/MenuDropdown";var X4=Object.defineProperty,q4=Object.defineProperties,K4=Object.getOwnPropertyDescriptors,Vv=Object.getOwnPropertySymbols,Q4=Object.prototype.hasOwnProperty,Z4=Object.prototype.propertyIsEnumerable,Hv=(e,t,r)=>t in e?X4(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,J4=(e,t)=>{for(var r in t||(t={}))Q4.call(t,r)&&Hv(e,r,t[r]);if(Vv)for(var r of Vv(t))Z4.call(t,r)&&Hv(e,r,t[r]);return e},e6=(e,t)=>q4(e,K4(t)),t6=Q((e,{color:t,radius:r})=>({item:e6(J4({},e.fn.fontStyles()),{WebkitTapHighlightColor:"transparent",fontSize:e.fontSizes.sm,border:0,backgroundColor:"transparent",outline:0,width:"100%",textAlign:"left",textDecoration:"none",boxSizing:"border-box",padding:`${e.spacing.xs}px ${e.spacing.sm}px`,cursor:"pointer",borderRadius:e.fn.radius(r),color:t?e.fn.variant({variant:"filled",primaryFallback:!1,color:t}).background:e.colorScheme==="dark"?e.colors.dark[0]:e.black,display:"flex",alignItems:"center","&:disabled":{color:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[5],pointerEvents:"none",userSelect:"none"},"&[data-hovered]":{backgroundColor:t?e.fn.variant({variant:"light",color:t}).background:e.colorScheme==="dark"?e.fn.rgba(e.colors.dark[3],.35):e.colors.gray[0]}}),itemLabel:{flex:1},itemIcon:{display:"flex",justifyContent:"center",alignItems:"center",marginRight:e.spacing.xs},itemRightSection:{}})),r6=t6,n6=Object.defineProperty,o6=Object.defineProperties,i6=Object.getOwnPropertyDescriptors,os=Object.getOwnPropertySymbols,xS=Object.prototype.hasOwnProperty,PS=Object.prototype.propertyIsEnumerable,Bv=(e,t,r)=>t in e?n6(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,l6=(e,t)=>{for(var r in t||(t={}))xS.call(t,r)&&Bv(e,r,t[r]);if(os)for(var r of os(t))PS.call(t,r)&&Bv(e,r,t[r]);return e},a6=(e,t)=>o6(e,i6(t)),s6=(e,t)=>{var r={};for(var n in e)xS.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&os)for(var n of os(e))t.indexOf(n)<0&&PS.call(e,n)&&(r[n]=e[n]);return r};const $S=g.exports.forwardRef((e,t)=>{var r=e,{children:n,className:o,color:i,closeMenuOnClick:l,icon:a,rightSection:s}=r,u=s6(r,["children","className","color","closeMenuOnClick","icon","rightSection"]);const c=rp(),{classNames:f,styles:d,unstyled:p}=dn(),{classes:y,cx:w,theme:v}=r6({radius:c.radius,color:i},{name:"Menu",classNames:f,styles:d,unstyled:p}),m=g.exports.useRef(),h=c.getItemIndex(m.current),_=u,b=Xt(_.onMouseLeave,()=>c.setHovered(-1)),O=Xt(_.onMouseEnter,()=>c.setHovered(c.getItemIndex(m.current))),x=Xt(_.onClick,()=>{typeof l=="boolean"?l&&c.closeDropdownImmediately():c.closeOnItemClick&&c.closeDropdownImmediately()}),P=Xt(_.onFocus,()=>c.setHovered(c.getItemIndex(m.current)));return U(q,{...a6(l6({component:"button"},u),{type:"button",tabIndex:-1,onFocus:P,className:w(y.item,o),ref:pn(m,t),role:"menuitem","data-menu-item":!0,"data-hovered":c.hovered===h?!0:void 0,onMouseEnter:O,onMouseLeave:b,onClick:x,onKeyDown:g1({siblingSelector:"[data-menu-item]",parentSelector:"[data-menu-dropdown]",activateOnFocus:!1,loop:c.loop,dir:v.dir,orientation:"vertical",onKeyDown:_.onKeydown})}),children:[a&&S("div",{className:y.itemIcon,children:a}),n&&S("div",{className:y.itemLabel,children:n}),s&&S("div",{className:y.itemRightSection,children:s})]})});$S.displayName="@mantine/core/MenuItem";const u6=$S;var c6=Q(e=>({label:{color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6],fontWeight:500,fontSize:e.fontSizes.xs,padding:`${e.spacing.xs/2}px ${e.spacing.sm}px`,cursor:"default"}})),f6=c6,d6=Object.defineProperty,is=Object.getOwnPropertySymbols,OS=Object.prototype.hasOwnProperty,CS=Object.prototype.propertyIsEnumerable,Wv=(e,t,r)=>t in e?d6(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,p6=(e,t)=>{for(var r in t||(t={}))OS.call(t,r)&&Wv(e,r,t[r]);if(is)for(var r of is(t))CS.call(t,r)&&Wv(e,r,t[r]);return e},g6=(e,t)=>{var r={};for(var n in e)OS.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&is)for(var n of is(e))t.indexOf(n)<0&&CS.call(e,n)&&(r[n]=e[n]);return r};function ES(e){var t=e,{children:r,className:n}=t,o=g6(t,["children","className"]);const{classNames:i,styles:l,unstyled:a}=dn(),{classes:s,cx:u}=f6(null,{name:"Menu",classNames:i,styles:l,unstyled:a});return E.createElement(mt,p6({className:u(s.label,n)},o),r)}ES.displayName="@mantine/core/MenuLabel";var m6=Object.defineProperty,ls=Object.getOwnPropertySymbols,kS=Object.prototype.hasOwnProperty,RS=Object.prototype.propertyIsEnumerable,Uv=(e,t,r)=>t in e?m6(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,v6=(e,t)=>{for(var r in t||(t={}))kS.call(t,r)&&Uv(e,r,t[r]);if(ls)for(var r of ls(t))RS.call(t,r)&&Uv(e,r,t[r]);return e},h6=(e,t)=>{var r={};for(var n in e)kS.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&ls)for(var n of ls(e))t.indexOf(n)<0&&RS.call(e,n)&&(r[n]=e[n]);return r};const IS=g.exports.forwardRef((e,t)=>{var r=e,{children:n,refProp:o="ref"}=r,i=h6(r,["children","refProp"]);if(!Ti(n))throw new Error(wS.children);const l=rp(),a=Xt(n.props.onClick,()=>l.trigger==="click"&&l.toggleDropdown()),s=Xt(n.props.onMouseEnter,()=>l.trigger==="hover"&&l.openDropdown()),u=Xt(n.props.onMouseLeave,()=>l.trigger==="hover"&&l.closeDropdown());return S(nr.Target,{...v6({refProp:o,popupType:"menu",ref:t},i),children:g.exports.cloneElement(n,{onClick:a,onMouseEnter:s,onMouseLeave:u,"data-expanded":l.opened?!0:void 0})})});IS.displayName="@mantine/core/MenuTarget";var y6=Q({dropdown:{padding:4}}),w6=y6,_6=Object.defineProperty,S6=Object.defineProperties,b6=Object.getOwnPropertyDescriptors,as=Object.getOwnPropertySymbols,NS=Object.prototype.hasOwnProperty,zS=Object.prototype.propertyIsEnumerable,Gv=(e,t,r)=>t in e?_6(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Yv=(e,t)=>{for(var r in t||(t={}))NS.call(t,r)&&Gv(e,r,t[r]);if(as)for(var r of as(t))zS.call(t,r)&&Gv(e,r,t[r]);return e},Xv=(e,t)=>S6(e,b6(t)),x6=(e,t)=>{var r={};for(var n in e)NS.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&as)for(var n of as(e))t.indexOf(n)<0&&zS.call(e,n)&&(r[n]=e[n]);return r};const P6={closeOnItemClick:!0,loop:!0,trigger:"click",openDelay:0,closeDelay:100};function et(e){const t=ee("Menu",P6,e),{children:r,onOpen:n,onClose:o,opened:i,defaultOpened:l,onChange:a,closeOnItemClick:s,loop:u,closeOnEscape:c,trigger:f,openDelay:d,closeDelay:p,classNames:y,styles:w,unstyled:v,radius:m}=t,h=x6(t,["children","onOpen","onClose","opened","defaultOpened","onChange","closeOnItemClick","loop","closeOnEscape","trigger","openDelay","closeDelay","classNames","styles","unstyled","radius"]),{classes:_,cx:b}=w6(),[O,{setHovered:x,resetHovered:P}]=N$(),[$,C]=Li({value:i,defaultValue:l,finalValue:!1,onChange:a}),I=()=>{C(!1),$&&o?.()},z=()=>{C(!0),!$&&n?.()},D=()=>$?I():z(),{openDropdown:j,closeDropdown:B}=L4({open:z,close:I,closeDelay:p,openDelay:d}),V=W=>$$("[data-menu-item]","[data-menu-dropdown]",W);return kr(()=>{P()},[$]),E.createElement(W4,{value:{opened:$,toggleDropdown:D,getItemIndex:V,hovered:O,setHovered:x,closeOnItemClick:s,closeDropdown:f==="click"?I:B,openDropdown:f==="click"?z:j,closeDropdownImmediately:I,loop:u,trigger:f,radius:m}},E.createElement(nr,Xv(Yv({},h),{radius:m,opened:$,onChange:C,defaultOpened:l,trapFocus:f==="click",closeOnEscape:c&&f==="click",__staticSelector:"Menu",classNames:Xv(Yv({},y),{dropdown:b(_.dropdown,y?.dropdown)}),styles:w,unstyled:v,onClose:I,onOpen:z}),r))}et.displayName="@mantine/core/Menu";et.Item=u6;et.Label=ES;et.Dropdown=bS;et.Target=IS;et.Divider=yS;var $6=Object.defineProperty,qv=Object.getOwnPropertySymbols,O6=Object.prototype.hasOwnProperty,C6=Object.prototype.propertyIsEnumerable,Kv=(e,t,r)=>t in e?$6(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,E6=(e,t)=>{for(var r in t||(t={}))O6.call(t,r)&&Kv(e,r,t[r]);if(qv)for(var r of qv(t))C6.call(t,r)&&Kv(e,r,t[r]);return e};const k6={xs:320,sm:380,md:440,lg:620,xl:780};function R6(e){return e?{position:"absolute",top:0,left:0,right:0,bottom:0}:{}}var I6=Q((e,{overflow:t,size:r,centered:n,zIndex:o,fullScreen:i})=>({close:{},overlay:{display:i?"none":void 0},root:{position:"fixed",zIndex:o,top:0,left:0,right:0,bottom:0},inner:{position:"absolute",top:0,left:0,right:0,bottom:0,overflowY:"auto",padding:i?0:`${e.spacing.xl*2}px ${e.spacing.md}px`,display:"flex",justifyContent:"center",alignItems:n?"center":"flex-start"},title:{marginRight:e.spacing.md,textOverflow:"ellipsis",display:"block",wordBreak:"break-word"},modal:E6({position:"relative",width:i?void 0:e.fn.size({sizes:k6,size:r}),borderRadius:i?0:void 0,outline:0,backgroundColor:e.colorScheme==="dark"?e.colors.dark[7]:e.white,marginTop:n?"auto":void 0,marginBottom:n?"auto":void 0,zIndex:1,marginLeft:i?void 0:"calc(var(--removed-scroll-width, 0px) * -1)"},R6(i)),header:{display:"flex",alignItems:"center",justifyContent:"space-between",marginBottom:e.spacing.md,marginRight:-9},body:{maxHeight:t==="inside"?"calc(100vh - 185px)":null,overflowY:t==="inside"?"auto":null,wordBreak:"break-word"}})),N6=I6,z6=Object.defineProperty,ss=Object.getOwnPropertySymbols,DS=Object.prototype.hasOwnProperty,TS=Object.prototype.propertyIsEnumerable,Qv=(e,t,r)=>t in e?z6(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,D6=(e,t)=>{for(var r in t||(t={}))DS.call(t,r)&&Qv(e,r,t[r]);if(ss)for(var r of ss(t))TS.call(t,r)&&Qv(e,r,t[r]);return e},T6=(e,t)=>{var r={};for(var n in e)DS.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&ss)for(var n of ss(e))t.indexOf(n)<0&&TS.call(e,n)&&(r[n]=e[n]);return r};const M6={size:"md",transitionDuration:250,overflow:"outside",padding:"lg",shadow:"lg",closeOnClickOutside:!0,closeOnEscape:!0,trapFocus:!0,withCloseButton:!0,withinPortal:!0,lockScroll:!0,withFocusReturn:!0,overlayBlur:0,zIndex:io("modal")};function mu(e){const t=ee("Modal",M6,e),{className:r,opened:n,title:o,onClose:i,children:l,withCloseButton:a,overlayOpacity:s,size:u,transitionDuration:c,closeButtonLabel:f,overlayColor:d,overflow:p,transition:y,padding:w,shadow:v,radius:m,id:h,classNames:_,styles:b,closeOnClickOutside:O,trapFocus:x,closeOnEscape:P,centered:$,target:C,withinPortal:I,zIndex:z,overlayBlur:D,transitionTimingFunction:j,fullScreen:B,unstyled:V,lockScroll:W,withFocusReturn:re}=t,se=T6(t,["className","opened","title","onClose","children","withCloseButton","overlayOpacity","size","transitionDuration","closeButtonLabel","overlayColor","overflow","transition","padding","shadow","radius","id","classNames","styles","closeOnClickOutside","trapFocus","closeOnEscape","centered","target","withinPortal","zIndex","overlayBlur","transitionTimingFunction","fullScreen","unstyled","lockScroll","withFocusReturn"]),ie=lo(h),Ne=`${ie}-title`,R=`${ie}-body`,{classes:T,cx:A,theme:k}=N6({size:u,overflow:p,centered:$,zIndex:z,fullScreen:B},{unstyled:V,classNames:_,styles:b,name:"Modal"}),M=X1(x&&n),G=typeof s=="number"?s:k.colorScheme==="dark"?.85:.75,[,Z]=_2(),ze=ae=>{!x&&ae.key==="Escape"&&P&&i()};return g.exports.useEffect(()=>{if(!x)return window.addEventListener("keydown",ze),()=>window.removeEventListener("keydown",ze)},[x]),W1({opened:n,shouldReturnFocus:x&&re}),S(Fi,{withinPortal:I,target:C,children:S(iS,{onExited:()=>W&&Z(!1),onEntered:()=>W&&Z(!0),mounted:n,duration:c,exitDuration:c,timingFunction:j,transitions:{modal:{duration:c,transition:y||(B?"fade":"pop")},overlay:{duration:c/2,transition:"fade",timingFunction:"ease"}},children:ae=>S(q,{...D6({id:ie,className:A(T.root,r)},se),children:U("div",{className:T.inner,onKeyDownCapture:Ae=>{var or;((or=Ae.target)==null?void 0:or.getAttribute("data-mantine-stop-propagation"))!=="true"&&Ae.key==="Escape"&&P&&i()},ref:M,children:[U(GR,{className:T.modal,shadow:v,p:w,radius:m,role:"dialog","aria-labelledby":Ne,"aria-describedby":R,"aria-modal":!0,tabIndex:-1,style:ae.modal,unstyled:V,children:[(o||a)&&U("div",{className:T.header,children:[S(mt,{id:Ne,className:T.title,children:o}),a&&S(iu,{iconSize:16,onClick:i,"aria-label":f,className:T.close})]}),S("div",{id:R,className:T.body,children:l})]}),S("div",{style:ae.overlay,children:S(h4,{className:T.overlay,sx:{position:"fixed"},zIndex:0,onMouseDown:()=>O&&i(),blur:D,color:d||(k.colorScheme==="dark"?k.colors.dark[9]:k.black),opacity:G,unstyled:V})})]})})})})}mu.displayName="@mantine/core/Modal";var j6=Object.defineProperty,us=Object.getOwnPropertySymbols,MS=Object.prototype.hasOwnProperty,jS=Object.prototype.propertyIsEnumerable,Zv=(e,t,r)=>t in e?j6(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Jv=(e,t)=>{for(var r in t||(t={}))MS.call(t,r)&&Zv(e,r,t[r]);if(us)for(var r of us(t))jS.call(t,r)&&Zv(e,r,t[r]);return e},L6=(e,t)=>{var r={};for(var n in e)MS.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&us)for(var n of us(e))t.indexOf(n)<0&&jS.call(e,n)&&(r[n]=e[n]);return r};const F6={xs:14,sm:18,md:20,lg:24,xl:28};function A6(e){var t=e,{size:r,error:n,style:o}=t,i=L6(t,["size","error","style"]);const l=at(),a=l.fn.size({size:r,sizes:F6});return E.createElement("svg",Jv({width:a,height:a,viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg",style:Jv({color:n?l.colors.red[6]:l.colors.gray[6]},o),"data-chevron":!0},i),E.createElement("path",{d:"M4.93179 5.43179C4.75605 5.60753 4.75605 5.89245 4.93179 6.06819C5.10753 6.24392 5.39245 6.24392 5.56819 6.06819L7.49999 4.13638L9.43179 6.06819C9.60753 6.24392 9.89245 6.24392 10.0682 6.06819C10.2439 5.89245 10.2439 5.60753 10.0682 5.43179L7.81819 3.18179C7.73379 3.0974 7.61933 3.04999 7.49999 3.04999C7.38064 3.04999 7.26618 3.0974 7.18179 3.18179L4.93179 5.43179ZM10.0682 9.56819C10.2439 9.39245 10.2439 9.10753 10.0682 8.93179C9.89245 8.75606 9.60753 8.75606 9.43179 8.93179L7.49999 10.8636L5.56819 8.93179C5.39245 8.75606 5.10753 8.75606 4.93179 8.93179C4.75605 9.10753 4.75605 9.39245 4.93179 9.56819L7.18179 11.8182C7.35753 11.9939 7.64245 11.9939 7.81819 11.8182L10.0682 9.56819Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}function LS({shouldClear:e,clearButtonLabel:t,onClear:r,size:n,error:o,clearButtonTabIndex:i}){return e?E.createElement(iu,{variant:"transparent","aria-label":t,onClick:r,size:n,tabIndex:i}):E.createElement(A6,{error:o,size:n})}LS.displayName="@mantine/core/SelectRightSection";var V6=Object.defineProperty,H6=Object.defineProperties,B6=Object.getOwnPropertyDescriptors,cs=Object.getOwnPropertySymbols,FS=Object.prototype.hasOwnProperty,AS=Object.prototype.propertyIsEnumerable,eh=(e,t,r)=>t in e?V6(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,lc=(e,t)=>{for(var r in t||(t={}))FS.call(t,r)&&eh(e,r,t[r]);if(cs)for(var r of cs(t))AS.call(t,r)&&eh(e,r,t[r]);return e},th=(e,t)=>H6(e,B6(t)),W6=(e,t)=>{var r={};for(var n in e)FS.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&cs)for(var n of cs(e))t.indexOf(n)<0&&AS.call(e,n)&&(r[n]=e[n]);return r};const U6={xs:24,sm:30,md:34,lg:44,xl:54};function G6(e){var t=e,{styles:r,rightSection:n,rightSectionWidth:o,theme:i}=t,l=W6(t,["styles","rightSection","rightSectionWidth","theme"]);if(n)return{rightSection:n,rightSectionWidth:o,styles:r};const a=typeof r=="function"?r(i):r;return{rightSectionWidth:i.fn.size({size:l.size,sizes:U6}),rightSection:!l.readOnly&&!(l.disabled&&l.shouldClear)&&E.createElement(LS,lc({},l)),styles:th(lc({},a),{rightSection:th(lc({},a?.rightSection),{pointerEvents:l.shouldClear?void 0:"none"})})}}const Y6=(e,t,r)=>Number.isInteger(e)&&e>=0&&t===0?"numeric":!Number.isInteger(e)&&e>=0&&t!==0?"decimal":Number.isInteger(e)&&e<0&&t===0||!Number.isInteger(e)&&e<0&&t!==0?r==="ios"?"text":"decimal":"numeric";function rh({direction:e,size:t}){return E.createElement("svg",{style:{transform:e==="up"?"rotate(180deg)":void 0},width:t,height:t,viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg"},E.createElement("path",{d:"M3.13523 6.15803C3.3241 5.95657 3.64052 5.94637 3.84197 6.13523L7.5 9.56464L11.158 6.13523C11.3595 5.94637 11.6759 5.95657 11.8648 6.15803C12.0536 6.35949 12.0434 6.67591 11.842 6.86477L7.84197 10.6148C7.64964 10.7951 7.35036 10.7951 7.15803 10.6148L3.15803 6.86477C2.95657 6.67591 2.94637 6.35949 3.13523 6.15803Z",fill:"currentColor",fillRule:"evenodd",clipRule:"evenodd"}))}const VS={xs:20,sm:24,md:30,lg:34,xl:36};var X6=Q((e,{radius:t,size:r})=>({rightSection:{display:"flex",flexDirection:"column",height:"calc(100% - 2px)",margin:1,marginRight:1,overflow:"hidden",borderTopRightRadius:e.fn.radius(t),borderBottomRightRadius:e.fn.radius(t)},control:{margin:0,position:"relative",flex:"0 0 50%",display:"flex",alignItems:"center",justifyContent:"center",boxSizing:"border-box",width:e.fn.size({size:r,sizes:VS}),padding:0,WebkitTapHighlightColor:"transparent",borderBottom:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4]}`,borderLeft:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4]}`,borderTop:0,borderRight:0,backgroundColor:"transparent",marginRight:1,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,"&:not(:disabled):hover":{backgroundColor:e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[0]},"&:disabled":{color:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[4]}},controlUp:{},controlDown:{borderBottom:0}})),q6=X6,K6=Object.defineProperty,Q6=Object.defineProperties,Z6=Object.getOwnPropertyDescriptors,fs=Object.getOwnPropertySymbols,HS=Object.prototype.hasOwnProperty,BS=Object.prototype.propertyIsEnumerable,nh=(e,t,r)=>t in e?K6(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,ac=(e,t)=>{for(var r in t||(t={}))HS.call(t,r)&&nh(e,r,t[r]);if(fs)for(var r of fs(t))BS.call(t,r)&&nh(e,r,t[r]);return e},J6=(e,t)=>Q6(e,Z6(t)),eI=(e,t)=>{var r={};for(var n in e)HS.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&fs)for(var n of fs(e))t.indexOf(n)<0&&BS.call(e,n)&&(r[n]=e[n]);return r};const tI={type:"text",size:"sm",__staticSelector:"TextInput"},Tr=g.exports.forwardRef((e,t)=>{const r=k_("TextInput",tI,e),{inputProps:n,wrapperProps:o}=r,i=eI(r,["inputProps","wrapperProps"]);return S(Ua.Wrapper,{...ac({},o),children:S(Ua,{...J6(ac(ac({},n),i),{ref:t})})})});Tr.displayName="@mantine/core/TextInput";var rI=Object.defineProperty,nI=Object.defineProperties,oI=Object.getOwnPropertyDescriptors,ds=Object.getOwnPropertySymbols,WS=Object.prototype.hasOwnProperty,US=Object.prototype.propertyIsEnumerable,oh=(e,t,r)=>t in e?rI(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,iI=(e,t)=>{for(var r in t||(t={}))WS.call(t,r)&&oh(e,r,t[r]);if(ds)for(var r of ds(t))US.call(t,r)&&oh(e,r,t[r]);return e},lI=(e,t)=>nI(e,oI(t)),aI=(e,t)=>{var r={};for(var n in e)WS.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&ds)for(var n of ds(e))t.indexOf(n)<0&&US.call(e,n)&&(r[n]=e[n]);return r};const sI=e=>e||"",uI=e=>{if(e==="-")return e;let t=e;t[0]==="."&&(t=`0${e}`);const r=parseFloat(t);if(!Number.isNaN(r))return e},ih={xs:10,sm:14,md:16,lg:18,xl:20},cI={step:1,hideControls:!1,size:"sm",precision:0,noClampOnBlur:!1,formatter:sI,parser:uI},$i=g.exports.forwardRef((e,t)=>{const r=ee("NumberInput",cI,e),{disabled:n,value:o,onChange:i,decimalSeparator:l,min:a,max:s,startValue:u,step:c,stepHoldInterval:f,stepHoldDelay:d,onBlur:p,onFocus:y,hideControls:w,radius:v,variant:m,precision:h,defaultValue:_,noClampOnBlur:b,handlersRef:O,classNames:x,styles:P,size:$,rightSection:C,rightSectionWidth:I,formatter:z,parser:D,inputMode:j,unstyled:B}=r,V=aI(r,["disabled","value","onChange","decimalSeparator","min","max","startValue","step","stepHoldInterval","stepHoldDelay","onBlur","onFocus","hideControls","radius","variant","precision","defaultValue","noClampOnBlur","handlersRef","classNames","styles","size","rightSection","rightSectionWidth","formatter","parser","inputMode","unstyled"]),{classes:W,cx:re,theme:se}=q6({radius:v,size:$},{classNames:x,styles:P,unstyled:B,name:"NumberInput"}),[ie,Ne]=g.exports.useState(!1),[R,T]=g.exports.useState(typeof o=="number"?o:typeof _=="number"?_:void 0),A=typeof o=="number"?o:R,[k,M]=g.exports.useState(typeof A=="number"?A.toFixed(h):""),G=g.exports.useRef(),Z=H=>{H!==R&&!Number.isNaN(H)&&(typeof i=="function"&&i(H),T(H))},ze=(H="")=>{let ne=typeof H=="number"?String(H):H;return l&&(ne=ne.replace(/\./g,l)),z(ne)},ae=H=>{let ne=H;return l&&(ne=ne.replace(new RegExp(`\\${l}`,"g"),".")),D(ne)},Ae=typeof a=="number"?a:-1/0,or=typeof s=="number"?s:1/0,mn=g.exports.useRef();mn.current=()=>{var H,ne,me;if(R===void 0)Z((H=u??a)!=null?H:0),M((me=(ne=u?.toFixed(h))!=null?ne:a?.toFixed(h))!=null?me:"0");else{const Ve=Zu(R+c,Ae,or).toFixed(h);Z(parseFloat(Ve)),M(Ve)}};const co=g.exports.useRef();co.current=()=>{var H,ne,me;if(R===void 0)Z((H=u??a)!=null?H:0),M((me=(ne=u?.toFixed(h))!=null?ne:a?.toFixed(h))!=null?me:"0");else{const Ve=Zu(R-c,Ae,or).toFixed(h);Z(parseFloat(Ve)),M(Ve)}},q1(O,{increment:mn.current,decrement:co.current}),g.exports.useEffect(()=>{typeof o=="number"&&!ie&&(T(o),M(o.toFixed(h))),_===void 0&&o===void 0&&!ie&&(T(o),M(""))},[o]);const fo=d!==void 0&&f!==void 0,Ke=g.exports.useRef(null),po=g.exports.useRef(0),Lt=()=>{Ke.current&&window.clearTimeout(Ke.current),Ke.current=null,po.current=0},Gi=H=>{H?mn.current():co.current(),po.current+=1},Yi=H=>{if(Gi(H),fo){const ne=typeof f=="number"?f:f(po.current);Ke.current=window.setTimeout(()=>Yi(H),ne)}},Ee=(H,ne)=>{H.preventDefault(),G.current.focus(),Gi(ne),fo&&(Ke.current=window.setTimeout(()=>Yi(ne),d))};g.exports.useEffect(()=>(Lt(),Lt),[]);const bu=U("div",{className:W.rightSection,children:[S("button",{type:"button",tabIndex:-1,"aria-hidden":!0,disabled:A>=s,className:re(W.control,W.controlUp),onPointerDown:H=>{Ee(H,!0)},onPointerUp:Lt,onPointerLeave:Lt,children:S(rh,{size:se.fn.size({size:$,sizes:ih}),direction:"up"})}),S("button",{type:"button",tabIndex:-1,"aria-hidden":!0,disabled:A<=a,className:re(W.control,W.controlDown),onPointerDown:H=>{Ee(H,!1)},onPointerUp:Lt,onPointerLeave:Lt,children:S(rh,{size:se.fn.size({size:$,sizes:ih}),direction:"down"})})]}),wt=H=>{if(H.nativeEvent.isComposing)return;const me=H.target.value,Ve=ae(me);M(Ve),me===""||me==="-"?Z(void 0):me.trim()!==""&&!Number.isNaN(Ve)&&Z(parseFloat(Ve))},De=H=>{var ne;if(H.target.value==="")M(""),Z(void 0);else{let me=H.target.value;(me[0]===`${l}`||me[0]===".")&&(me=`0${me}`);const Ve=ae(me),mo=Zu(parseFloat(Ve),Ae,or);Number.isNaN(mo)?M((ne=A?.toFixed(h))!=null?ne:""):b||(M(mo.toFixed(h)),Z(parseFloat(mo.toFixed(h))))}Ne(!1),typeof p=="function"&&p(H)},go=H=>{Ne(!0),typeof y=="function"&&y(H)},vn=H=>{if(H.repeat&&fo&&(H.key==="ArrowUp"||H.key==="ArrowDown")){H.preventDefault();return}H.key==="ArrowUp"?Ee(H,!0):H.key==="ArrowDown"&&Ee(H,!1)},Xi=H=>{(H.key==="ArrowUp"||H.key==="ArrowDown")&&Lt()};return S(Tr,{...lI(iI({},V),{variant:m,value:ze(k),disabled:n,ref:pn(G,t),type:"text",onChange:wt,onBlur:De,onFocus:go,onKeyDown:vn,onKeyUp:Xi,rightSection:C||(n||w||m==="unstyled"?null:bu),rightSectionWidth:I||se.fn.size({size:$,sizes:VS})+1,radius:v,max:s,min:a,step:c,size:$,styles:P,classNames:x,inputMode:j||Y6(c,h,b2()),__staticSelector:"NumberInput",unstyled:B})})});$i.displayName="@mantine/core/NumberInput";var fI=Object.defineProperty,lh=Object.getOwnPropertySymbols,dI=Object.prototype.hasOwnProperty,pI=Object.prototype.propertyIsEnumerable,ah=(e,t,r)=>t in e?fI(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,gI=(e,t)=>{for(var r in t||(t={}))dI.call(t,r)&&ah(e,r,t[r]);if(lh)for(var r of lh(t))pI.call(t,r)&&ah(e,r,t[r]);return e};function GS(e){return E.createElement("svg",gI({width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),E.createElement("path",{d:"M2 8c0-.733.6-1.333 1.333-1.333.734 0 1.334.6 1.334 1.333s-.6 1.333-1.334 1.333C2.6 9.333 2 8.733 2 8zm9.333 0c0-.733.6-1.333 1.334-1.333C13.4 6.667 14 7.267 14 8s-.6 1.333-1.333 1.333c-.734 0-1.334-.6-1.334-1.333zM6.667 8c0-.733.6-1.333 1.333-1.333s1.333.6 1.333 1.333S8.733 9.333 8 9.333 6.667 8.733 6.667 8z",fill:"currentColor"}))}var mI=Object.defineProperty,sh=Object.getOwnPropertySymbols,vI=Object.prototype.hasOwnProperty,hI=Object.prototype.propertyIsEnumerable,uh=(e,t,r)=>t in e?mI(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,yI=(e,t)=>{for(var r in t||(t={}))vI.call(t,r)&&uh(e,r,t[r]);if(sh)for(var r of sh(t))hI.call(t,r)&&uh(e,r,t[r]);return e};function YS(e){return E.createElement("svg",yI({width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),E.createElement("path",{d:"M8.781 8l-3.3-3.3.943-.943L10.667 8l-4.243 4.243-.943-.943 3.3-3.3z",fill:"currentColor"}))}var wI=Object.defineProperty,ch=Object.getOwnPropertySymbols,_I=Object.prototype.hasOwnProperty,SI=Object.prototype.propertyIsEnumerable,fh=(e,t,r)=>t in e?wI(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,bI=(e,t)=>{for(var r in t||(t={}))_I.call(t,r)&&fh(e,r,t[r]);if(ch)for(var r of ch(t))SI.call(t,r)&&fh(e,r,t[r]);return e};function XS(e){return E.createElement("svg",bI({width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),E.createElement("path",{d:"M7.219 8l3.3 3.3-.943.943L5.333 8l4.243-4.243.943.943-3.3 3.3z",fill:"currentColor"}))}var xI=Object.defineProperty,dh=Object.getOwnPropertySymbols,PI=Object.prototype.hasOwnProperty,$I=Object.prototype.propertyIsEnumerable,ph=(e,t,r)=>t in e?xI(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,OI=(e,t)=>{for(var r in t||(t={}))PI.call(t,r)&&ph(e,r,t[r]);if(dh)for(var r of dh(t))$I.call(t,r)&&ph(e,r,t[r]);return e};function qS(e){return E.createElement("svg",OI({width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),E.createElement("path",{d:"M6.85355 3.85355C7.04882 3.65829 7.04882 3.34171 6.85355 3.14645C6.65829 2.95118 6.34171 2.95118 6.14645 3.14645L2.14645 7.14645C1.95118 7.34171 1.95118 7.65829 2.14645 7.85355L6.14645 11.8536C6.34171 12.0488 6.65829 12.0488 6.85355 11.8536C7.04882 11.6583 7.04882 11.3417 6.85355 11.1464L3.20711 7.5L6.85355 3.85355ZM12.8536 3.85355C13.0488 3.65829 13.0488 3.34171 12.8536 3.14645C12.6583 2.95118 12.3417 2.95118 12.1464 3.14645L8.14645 7.14645C7.95118 7.34171 7.95118 7.65829 8.14645 7.85355L12.1464 11.8536C12.3417 12.0488 12.6583 12.0488 12.8536 11.8536C13.0488 11.6583 13.0488 11.3417 12.8536 11.1464L9.20711 7.5L12.8536 3.85355Z",fill:"currentColor"}))}var CI=Object.defineProperty,gh=Object.getOwnPropertySymbols,EI=Object.prototype.hasOwnProperty,kI=Object.prototype.propertyIsEnumerable,mh=(e,t,r)=>t in e?CI(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,RI=(e,t)=>{for(var r in t||(t={}))EI.call(t,r)&&mh(e,r,t[r]);if(gh)for(var r of gh(t))kI.call(t,r)&&mh(e,r,t[r]);return e};function KS(e){return E.createElement("svg",RI({width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e),E.createElement("path",{d:"M2.14645 11.1464C1.95118 11.3417 1.95118 11.6583 2.14645 11.8536C2.34171 12.0488 2.65829 12.0488 2.85355 11.8536L6.85355 7.85355C7.04882 7.65829 7.04882 7.34171 6.85355 7.14645L2.85355 3.14645C2.65829 2.95118 2.34171 2.95118 2.14645 3.14645C1.95118 3.34171 1.95118 3.65829 2.14645 3.85355L5.79289 7.5L2.14645 11.1464ZM8.14645 11.1464C7.95118 11.3417 7.95118 11.6583 8.14645 11.8536C8.34171 12.0488 8.65829 12.0488 8.85355 11.8536L12.8536 7.85355C13.0488 7.65829 13.0488 7.34171 12.8536 7.14645L8.85355 3.14645C8.65829 2.95118 8.34171 2.95118 8.14645 3.14645C7.95118 3.34171 7.95118 3.65829 8.14645 3.85355L11.7929 7.5L8.14645 11.1464Z",fill:"currentColor"}))}var II=Object.defineProperty,ps=Object.getOwnPropertySymbols,QS=Object.prototype.hasOwnProperty,ZS=Object.prototype.propertyIsEnumerable,vh=(e,t,r)=>t in e?II(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,NI=(e,t)=>{for(var r in t||(t={}))QS.call(t,r)&&vh(e,r,t[r]);if(ps)for(var r of ps(t))ZS.call(t,r)&&vh(e,r,t[r]);return e},zI=(e,t)=>{var r={};for(var n in e)QS.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&ps)for(var n of ps(e))t.indexOf(n)<0&&ZS.call(e,n)&&(r[n]=e[n]);return r};const DI={dots:GS,next:YS,prev:XS,first:qS,last:KS},TI={dots:GS,prev:YS,next:XS,last:qS,first:KS};function JS(e){var t=e,{page:r,active:n,onClick:o}=t,i=zI(t,["page","active","onClick"]);const a=(at().dir==="rtl"?TI:DI)[r],s=a?E.createElement(a,null):r;return E.createElement("button",NI({type:"button",onClick:o},i),s)}JS.displayName="@mantine/core/Pagination/DefaultItem";var MI=Object.defineProperty,jI=Object.defineProperties,LI=Object.getOwnPropertyDescriptors,hh=Object.getOwnPropertySymbols,FI=Object.prototype.hasOwnProperty,AI=Object.prototype.propertyIsEnumerable,yh=(e,t,r)=>t in e?MI(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,VI=(e,t)=>{for(var r in t||(t={}))FI.call(t,r)&&yh(e,r,t[r]);if(hh)for(var r of hh(t))AI.call(t,r)&&yh(e,r,t[r]);return e},HI=(e,t)=>jI(e,LI(t));const wh={xs:22,sm:26,md:32,lg:38,xl:44};var BI=Q((e,{size:t,radius:r,color:n})=>{const o=e.fn.variant({color:n,variant:"filled"});return{item:HI(VI({},e.fn.focusStyles()),{cursor:"pointer",userSelect:"none",display:"flex",alignItems:"center",justifyContent:"center",fontWeight:500,border:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[4]}`,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,height:e.fn.size({size:t,sizes:wh}),minWidth:e.fn.size({size:t,sizes:wh}),padding:`0 ${e.fn.size({size:t,sizes:e.spacing})/2}px`,fontSize:e.fn.size({size:t,sizes:e.fontSizes}),borderRadius:e.fn.radius(r),lineHeight:1,backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.white,"&:active:not(:disabled):not([data-dots])":e.activeStyles,"&:disabled":{opacity:.6,cursor:"not-allowed",color:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[5]},"&[data-dots]":{cursor:"default",borderColor:"transparent",backgroundColor:"transparent"},"&[data-active]":{borderColor:"transparent",color:o.color,backgroundColor:o.background}})}}),WI=BI,UI=Object.defineProperty,gs=Object.getOwnPropertySymbols,eb=Object.prototype.hasOwnProperty,tb=Object.prototype.propertyIsEnumerable,_h=(e,t,r)=>t in e?UI(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,GI=(e,t)=>{for(var r in t||(t={}))eb.call(t,r)&&_h(e,r,t[r]);if(gs)for(var r of gs(t))tb.call(t,r)&&_h(e,r,t[r]);return e},YI=(e,t)=>{var r={};for(var n in e)eb.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&gs)for(var n of gs(e))t.indexOf(n)<0&&tb.call(e,n)&&(r[n]=e[n]);return r};const XI={itemComponent:JS,initialPage:1,siblings:1,boundaries:1,size:"md",radius:"sm",withEdges:!1,withControls:!0},rb=g.exports.forwardRef((e,t)=>{const r=ee("Pagination",XI,e),{itemComponent:n,classNames:o,styles:i,page:l,initialPage:a,color:s,total:u,siblings:c,boundaries:f,size:d,radius:p,onChange:y,getItemAriaLabel:w,spacing:v,withEdges:m,withControls:h,sx:_,unstyled:b}=r,O=YI(r,["itemComponent","classNames","styles","page","initialPage","color","total","siblings","boundaries","size","radius","onChange","getItemAriaLabel","spacing","withEdges","withControls","sx","unstyled"]),{classes:x,theme:P}=WI({color:s,size:d,radius:p},{classNames:o,styles:i,unstyled:b,name:"Pagination"}),{range:$,setPage:C,next:I,previous:z,active:D,first:j,last:B}=u2({page:l,siblings:c,total:u,onChange:y,initialPage:a,boundaries:f}),V=$.map((W,re)=>S(n,{page:W,active:W===D,"aria-current":W===D?"page":void 0,"aria-label":typeof w=="function"?w(W):null,tabIndex:W==="dots"?-1:0,"data-dots":W==="dots"||void 0,"data-active":W===D||void 0,className:x.item,onClick:W!=="dots"?()=>C(W):void 0},re));return U(jt,{...GI({role:"navigation",spacing:v||P.fn.size({size:d,sizes:P.spacing})/2,ref:t,sx:_,unstyled:b},O),children:[m&&S(n,{page:"first",onClick:j,"aria-label":w?w("first"):void 0,"aria-disabled":D===1,className:x.item,disabled:D===1}),h&&S(n,{page:"prev",onClick:z,"aria-label":w?w("prev"):void 0,"aria-disabled":D===1,className:x.item,disabled:D===1}),V,h&&S(n,{page:"next",onClick:I,"aria-label":w?w("next"):void 0,"aria-disabled":D===u,className:x.item,disabled:D===u}),m&&S(n,{page:"last",onClick:B,"aria-label":w?w("last"):void 0,"aria-disabled":D===u,className:x.item,disabled:D===u})]})});rb.displayName="@mantine/core/Pagination";function qI({data:e,searchable:t,limit:r,searchValue:n,filter:o,value:i,filterDataOnExactSearchMatch:l}){if(!t)return e;const a=i!=null&&e.find(u=>u.value===i)||null;if(a&&!l&&a?.label===n)return e;const s=[];for(let u=0;u=r));u+=1);return s}var KI=Q(()=>({input:{"&:not(:disabled)":{cursor:"pointer","&::selection":{backgroundColor:"transparent"}}}})),QI=KI,ZI=Object.defineProperty,JI=Object.defineProperties,e8=Object.getOwnPropertyDescriptors,ms=Object.getOwnPropertySymbols,nb=Object.prototype.hasOwnProperty,ob=Object.prototype.propertyIsEnumerable,Sh=(e,t,r)=>t in e?ZI(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,To=(e,t)=>{for(var r in t||(t={}))nb.call(t,r)&&Sh(e,r,t[r]);if(ms)for(var r of ms(t))ob.call(t,r)&&Sh(e,r,t[r]);return e},sc=(e,t)=>JI(e,e8(t)),t8=(e,t)=>{var r={};for(var n in e)nb.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&ms)for(var n of ms(e))t.indexOf(n)<0&&ob.call(e,n)&&(r[n]=e[n]);return r};function r8(e,t){return t.label.toLowerCase().trim().includes(e.toLowerCase().trim())}function n8(e,t){return!!e&&!t.some(r=>r.label.toLowerCase()===e.toLowerCase())}const o8={required:!1,size:"sm",shadow:"sm",itemComponent:kw,transition:"fade",transitionDuration:0,initiallyOpened:!1,filter:r8,maxDropdownHeight:220,searchable:!1,clearable:!1,limit:1/0,disabled:!1,creatable:!1,shouldCreate:n8,selectOnBlur:!1,switchDirectionOnFlip:!1,filterDataOnExactSearchMatch:!1,zIndex:io("popover"),clearButtonTabIndex:0,positionDependencies:[],dropdownPosition:"flip"},Oi=g.exports.forwardRef((e,t)=>{const r=k_("Select",o8,e),{inputProps:n,wrapperProps:o,shadow:i,data:l,value:a,defaultValue:s,onChange:u,itemComponent:c,onKeyDown:f,onBlur:d,onFocus:p,transition:y,transitionDuration:w,initiallyOpened:v,transitionTimingFunction:m,unstyled:h,classNames:_,styles:b,filter:O,maxDropdownHeight:x,searchable:P,clearable:$,nothingFound:C,clearButtonLabel:I,limit:z,disabled:D,onSearchChange:j,rightSection:B,rightSectionWidth:V,creatable:W,getCreateLabel:re,shouldCreate:se,selectOnBlur:ie,onCreate:Ne,dropdownComponent:R,onDropdownClose:T,onDropdownOpen:A,withinPortal:k,switchDirectionOnFlip:M,zIndex:G,name:Z,dropdownPosition:ze,allowDeselect:ae,placeholder:Ae,filterDataOnExactSearchMatch:or,clearButtonTabIndex:mn,form:co,positionDependencies:fo,readOnly:Ke}=r,po=t8(r,["inputProps","wrapperProps","shadow","data","value","defaultValue","onChange","itemComponent","onKeyDown","onBlur","onFocus","transition","transitionDuration","initiallyOpened","transitionTimingFunction","unstyled","classNames","styles","filter","maxDropdownHeight","searchable","clearable","nothingFound","clearButtonLabel","limit","disabled","onSearchChange","rightSection","rightSectionWidth","creatable","getCreateLabel","shouldCreate","selectOnBlur","onCreate","dropdownComponent","onDropdownClose","onDropdownOpen","withinPortal","switchDirectionOnFlip","zIndex","name","dropdownPosition","allowDeselect","placeholder","filterDataOnExactSearchMatch","clearButtonTabIndex","form","positionDependencies","readOnly"]),{classes:Lt,cx:Gi,theme:Yi}=QI(),[Ee,bu]=g.exports.useState(v),[wt,De]=g.exports.useState(-1),go=g.exports.useRef(),vn=g.exports.useRef({}),[Xi,H]=g.exports.useState("column"),ne=Xi==="column",{scrollIntoView:me,targetRef:Ve,scrollableRef:mo}=g2({duration:0,offset:5,cancelable:!1,isList:!0}),ax=ae===void 0?$:ae,st=F=>{if(Ee!==F){bu(F);const pe=F?A:T;typeof pe=="function"&&pe()}},xu=W&&typeof re=="function";let Pu=null;const sx=l.map(F=>typeof F=="string"?{label:F,value:F}:F),qi=z$({data:sx}),[_t,hn,pp]=Li({value:a,defaultValue:s,finalValue:null,onChange:u}),Ft=qi.find(F=>F.value===_t),[Mr,ux]=g.exports.useState(Ft?.label||""),jr=F=>{ux(F),P&&typeof j=="function"&&j(F)},cx=()=>{var F;Ke||(hn(null),pp||jr(""),(F=go.current)==null||F.focus())};g.exports.useEffect(()=>{const F=qi.find(pe=>pe.value===_t);F?jr(F.label):(!xu||!_t)&&jr("")},[_t]),g.exports.useEffect(()=>{Ft&&(!P||!Ee)&&jr(Ft.label)},[Ft?.label]);const Ki=F=>{if(!Ke)if(ax&&Ft?.value===F.value)hn(null),st(!1);else{if(F.creatable&&typeof Ne=="function"){const pe=Ne(F.value);hn(typeof pe=="string"?pe:pe.value)}else hn(F.value);pp||jr(F.label),De(-1),st(!1),go.current.focus()}},xe=qI({data:qi,searchable:P,limit:z,searchValue:Mr,filter:O,filterDataOnExactSearchMatch:or,value:_t});xu&&se(Mr,xe)&&(Pu=re(Mr),xe.push({label:Mr,value:Mr,creatable:!0}));const gp=(F,pe,Qe)=>{let Ze=F;for(;Qe(Ze);)if(Ze=pe(Ze),!xe[Ze].disabled)return Ze;return F};kr(()=>{De(-1)},[Mr]);const vo=_t?xe.findIndex(F=>F.value===_t):0,mp=()=>{De(F=>{var pe;const Qe=gp(F,Ze=>Ze-1,Ze=>Ze>0);return Ve.current=vn.current[(pe=xe[Qe])==null?void 0:pe.value],me({alignment:ne?"start":"end"}),Qe})},vp=()=>{De(F=>{var pe;const Qe=gp(F,Ze=>Ze+1,Ze=>Zewindow.setTimeout(()=>{var F;Ve.current=vn.current[(F=xe[vo])==null?void 0:F.value],me({alignment:ne?"end":"start"})},0),fx=F=>{switch(typeof f=="function"&&f(F),F.key){case"ArrowUp":{F.preventDefault(),Ee?ne?mp():vp():(De(vo),st(!0),ho());break}case"ArrowDown":{F.preventDefault(),Ee?ne?vp():mp():(De(vo),st(!0),ho());break}case"Home":{if(!P){F.preventDefault(),Ee||st(!0);const pe=xe.findIndex(Qe=>!Qe.disabled);De(pe),me({alignment:ne?"end":"start"})}break}case"End":{if(!P){F.preventDefault(),Ee||st(!0);const pe=xe.map(Qe=>!!Qe.disabled).lastIndexOf(!1);De(pe),me({alignment:ne?"end":"start"})}break}case"Escape":{F.preventDefault(),st(!1),De(-1);break}case" ":{P||(xe[wt]&&Ee?(F.preventDefault(),Ki(xe[wt])):(st(!0),De(vo),ho()));break}case"Enter":P||F.preventDefault(),xe[wt]&&Ee&&(F.preventDefault(),Ki(xe[wt]))}},dx=F=>{typeof d=="function"&&d(F);const pe=qi.find(Qe=>Qe.value===_t);ie&&xe[wt]&&Ee&&Ki(xe[wt]),jr(pe?.label||""),st(!1)},px=F=>{typeof p=="function"&&p(F),P&&(st(!0),ho())},gx=F=>{Ke||(jr(F.currentTarget.value),$&&F.currentTarget.value===""&&hn(null),De(-1),st(!0))},mx=()=>{if(!Ke){let F=!0;P||(F=!Ee),st(F),_t&&F&&(De(vo),ho())}},yo=!Ke&&(xe.length>0?Ee:Ee&&!!C);return S(Ua.Wrapper,{...sc(To({},o),{__staticSelector:"Select"}),children:U(ii,{opened:yo,transition:y,transitionDuration:w,shadow:"sm",withinPortal:k,__staticSelector:"Select",onDirectionChange:H,switchDirectionOnFlip:M,zIndex:G,dropdownPosition:ze,positionDependencies:fo,classNames:_,styles:b,unstyled:h,children:[S(ii.Target,{children:U("div",{role:"combobox","aria-haspopup":"listbox","aria-owns":yo?`${n.id}-items`:null,"aria-controls":n.id,"aria-expanded":yo,onMouseLeave:()=>De(-1),tabIndex:-1,children:[S("input",{type:"hidden",name:Z,value:_t||"",form:co,disabled:D}),S(Ua,{...To(sc(To(To({autoComplete:"off",type:"search"},n),po),{ref:pn(t,go),onKeyDown:fx,__staticSelector:"Select",value:Mr,placeholder:Ae,onChange:gx,"aria-autocomplete":"list","aria-controls":yo?`${n.id}-items`:null,"aria-activedescendant":wt>=0?`${n.id}-${wt}`:null,onClick:mx,onBlur:dx,onFocus:px,readOnly:!P||Ke,disabled:D,"data-mantine-stop-propagation":yo,name:null,classNames:sc(To({},_),{input:Gi({[Lt.input]:!P},_?.input)})}),G6({theme:Yi,rightSection:B,rightSectionWidth:V,styles:b,size:n.size,shouldClear:$&&!!Ft,clearButtonLabel:I,onClear:cx,error:o.error,clearButtonTabIndex:mn,disabled:D,readOnly:Ke}))})]})}),S(ii.Dropdown,{component:R||Ud,maxHeight:x,direction:Xi,id:n.id,innerRef:mo,children:S(Ow,{data:xe,hovered:wt,classNames:_,styles:b,isItemSelected:F=>F===_t,uuid:n.id,__staticSelector:"Select",onItemHover:De,onItemSelect:Ki,itemsRefs:vn,itemComponent:c,size:n.size,nothingFound:C,creatable:xu&&!!Pu,createLabel:Pu,"aria-label":o.label,unstyled:h})})]})})});Oi.displayName="@mantine/core/Select";function i8(e,t){if(t.length===0)return t;const r="maxWidth"in t[0]?"maxWidth":"minWidth",n=[...t].sort((o,i)=>e.fn.size({size:i[r],sizes:e.breakpoints})-e.fn.size({size:o[r],sizes:e.breakpoints}));return r==="minWidth"?n.reverse():n}var l8=Object.defineProperty,bh=Object.getOwnPropertySymbols,a8=Object.prototype.hasOwnProperty,s8=Object.prototype.propertyIsEnumerable,xh=(e,t,r)=>t in e?l8(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,u8=(e,t)=>{for(var r in t||(t={}))a8.call(t,r)&&xh(e,r,t[r]);if(bh)for(var r of bh(t))s8.call(t,r)&&xh(e,r,t[r]);return e},c8=Q((e,{spacing:t,breakpoints:r,cols:n})=>{const o=i8(e,r).reduce((i,l)=>{const a="maxWidth"in l?"max-width":"min-width",s=e.fn.size({size:a==="max-width"?l.maxWidth:l.minWidth,sizes:e.breakpoints});return i[`@media (${a}: ${s+(a==="max-width"?0:1)}px)`]={gridTemplateColumns:`repeat(${l.cols}, minmax(0, 1fr))`,gap:e.fn.size({size:l.spacing||t,sizes:e.spacing})},i},{});return{root:u8({boxSizing:"border-box",display:"grid",gridTemplateColumns:`repeat(${n}, minmax(0, 1fr))`,gap:e.fn.size({size:t,sizes:e.spacing})},o)}}),f8=c8,d8=Object.defineProperty,vs=Object.getOwnPropertySymbols,ib=Object.prototype.hasOwnProperty,lb=Object.prototype.propertyIsEnumerable,Ph=(e,t,r)=>t in e?d8(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,p8=(e,t)=>{for(var r in t||(t={}))ib.call(t,r)&&Ph(e,r,t[r]);if(vs)for(var r of vs(t))lb.call(t,r)&&Ph(e,r,t[r]);return e},g8=(e,t)=>{var r={};for(var n in e)ib.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&vs)for(var n of vs(e))t.indexOf(n)<0&&lb.call(e,n)&&(r[n]=e[n]);return r};const m8={breakpoints:[],cols:1,spacing:"md"},ab=g.exports.forwardRef((e,t)=>{const r=ee("SimpleGrid",m8,e),{className:n,breakpoints:o,cols:i,spacing:l,children:a,unstyled:s}=r,u=g8(r,["className","breakpoints","cols","spacing","children","unstyled"]),{classes:c,cx:f}=f8({breakpoints:o,cols:i,spacing:l},{unstyled:s,name:"SimpleGrid"});return S(q,{...p8({className:f(c.root,n),ref:t},u),children:a})});ab.displayName="@mantine/core/SimpleGrid";var v8=Object.defineProperty,h8=Object.defineProperties,y8=Object.getOwnPropertyDescriptors,$h=Object.getOwnPropertySymbols,w8=Object.prototype.hasOwnProperty,_8=Object.prototype.propertyIsEnumerable,Oh=(e,t,r)=>t in e?v8(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Ch=(e,t)=>{for(var r in t||(t={}))w8.call(t,r)&&Oh(e,r,t[r]);if($h)for(var r of $h(t))_8.call(t,r)&&Oh(e,r,t[r]);return e},Eh=(e,t)=>h8(e,y8(t));const S8={xs:16,sm:20,md:24,lg:30,xl:36},uc={xs:30,sm:38,md:46,lg:56,xl:68},kh={xs:12,sm:14,md:18,lg:22,xl:28},b8={xs:5,sm:6,md:7,lg:9,xl:11};var x8=Q((e,{size:t,radius:r,color:n,offLabel:o,onLabel:i})=>{const l=e.fn.size({size:t,sizes:kh}),a=e.fn.size({size:r,sizes:e.radius}),s=e.fn.variant({variant:"filled",color:n});return{root:{display:"flex",alignItems:"center"},input:Eh(Ch({},e.fn.focusStyles()),{overflow:"hidden",WebkitTapHighlightColor:"transparent",position:"relative",borderRadius:a,backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[2],border:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3]}`,height:e.fn.size({size:t,sizes:S8}),width:e.fn.size({size:t,sizes:uc}),minWidth:e.fn.size({size:t,sizes:uc}),margin:0,transitionProperty:"background-color, border-color",transitionTimingFunction:e.transitionTimingFunction,transitionDuration:"150ms",boxSizing:"border-box",appearance:"none",display:"flex",alignItems:"center",fontSize:e.fn.size({size:t,sizes:b8}),fontWeight:600,cursor:e.cursorType,"&::before":{zIndex:1,borderRadius:a,boxSizing:"border-box",content:'""',display:"block",backgroundColor:e.white,height:l,width:l,border:`1px solid ${e.colorScheme==="dark"?e.white:e.colors.gray[3]}`,transition:`transform 150ms ${e.transitionTimingFunction}`,transform:`translateX(${t==="xs"?1:2}px)`,"@media (prefers-reduced-motion)":{transitionDuration:e.respectReducedMotion?"0ms":!1}},"&::after":{position:"absolute",zIndex:0,display:"flex",height:"100%",alignItems:"center",lineHeight:0,right:"10%",transform:"translateX(0)",content:o?`'${o}'`:"''",color:e.colorScheme==="dark"?e.colors.dark[1]:e.colors.gray[6],transition:`color 150ms ${e.transitionTimingFunction}`},"&:checked":{backgroundColor:s.background,borderColor:s.background,"&::before":{transform:`translateX(${e.fn.size({size:t,sizes:uc})-e.fn.size({size:t,sizes:kh})-(t==="xs"?3:4)}px)`,borderColor:e.white},"&::after":{position:"absolute",zIndex:0,display:"flex",height:"100%",alignItems:"center",lineHeight:0,left:"10%",transform:"translateX(0)",content:i?`'${i}'`:"''",color:e.white,transition:`color 150ms ${e.transitionTimingFunction}`}},"&:disabled":{backgroundColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2],borderColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2],cursor:"not-allowed","&::before":{borderColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[2],backgroundColor:e.colorScheme==="dark"?e.colors.dark[3]:e.colors.gray[0]}}}),label:Eh(Ch({},e.fn.fontStyles()),{WebkitTapHighlightColor:"transparent",fontSize:e.fn.size({size:t,sizes:e.fontSizes}),fontFamily:e.fontFamily,paddingLeft:e.spacing.sm,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,cursor:e.cursorType})}}),P8=x8,$8=Object.defineProperty,O8=Object.defineProperties,C8=Object.getOwnPropertyDescriptors,hs=Object.getOwnPropertySymbols,sb=Object.prototype.hasOwnProperty,ub=Object.prototype.propertyIsEnumerable,Rh=(e,t,r)=>t in e?$8(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,cc=(e,t)=>{for(var r in t||(t={}))sb.call(t,r)&&Rh(e,r,t[r]);if(hs)for(var r of hs(t))ub.call(t,r)&&Rh(e,r,t[r]);return e},E8=(e,t)=>O8(e,C8(t)),k8=(e,t)=>{var r={};for(var n in e)sb.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&hs)for(var n of hs(e))t.indexOf(n)<0&&ub.call(e,n)&&(r[n]=e[n]);return r};const R8={offLabel:"",onLabel:"",size:"sm",radius:"xl"},np=g.exports.forwardRef((e,t)=>{const r=ee("Switch",R8,e),{className:n,color:o,label:i,offLabel:l,onLabel:a,id:s,style:u,size:c,radius:f,wrapperProps:d,children:p,unstyled:y,styles:w,classNames:v,sx:m}=r,h=k8(r,["className","color","label","offLabel","onLabel","id","style","size","radius","wrapperProps","children","unstyled","styles","classNames","sx"]),{classes:_,cx:b}=P8({size:c,color:o,radius:f,offLabel:l,onLabel:a},{unstyled:y,styles:w,classNames:v,name:"Switch"}),{systemStyles:O,rest:x}=nu(h),P=lo(s);return U(q,{...cc(cc({className:b(_.root,n),style:u,sx:m},O),d),children:[S("input",{...E8(cc({},x),{id:P,ref:t,type:"checkbox",className:_.input})}),i&&S("label",{className:_.label,htmlFor:P,children:i})]})});np.displayName="@mantine/core/Switch";var I8=Object.defineProperty,N8=Object.defineProperties,z8=Object.getOwnPropertyDescriptors,Ih=Object.getOwnPropertySymbols,D8=Object.prototype.hasOwnProperty,T8=Object.prototype.propertyIsEnumerable,Nh=(e,t,r)=>t in e?I8(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,M8=(e,t)=>{for(var r in t||(t={}))D8.call(t,r)&&Nh(e,r,t[r]);if(Ih)for(var r of Ih(t))T8.call(t,r)&&Nh(e,r,t[r]);return e},j8=(e,t)=>N8(e,z8(t)),L8=Q((e,{captionSide:t,horizontalSpacing:r,verticalSpacing:n,fontSize:o})=>({root:j8(M8({},e.fn.fontStyles()),{width:"100%",borderCollapse:"collapse",captionSide:t,color:e.colorScheme==="dark"?e.colors.dark[0]:e.black,lineHeight:e.lineHeight,"& caption":{marginTop:t==="top"?0:e.spacing.xs,marginBottom:t==="bottom"?0:e.spacing.xs,fontSize:e.fontSizes.sm,color:e.colorScheme==="dark"?e.colors.dark[2]:e.colors.gray[6]},"& thead tr th, & tfoot tr th":{textAlign:"left",fontWeight:"bold",color:e.colorScheme==="dark"?e.colors.dark[0]:e.colors.gray[7],fontSize:e.fn.size({size:o,sizes:e.fontSizes}),padding:`${e.fn.size({size:n,sizes:e.spacing})}px ${e.fn.size({size:r,sizes:e.spacing})}px`},"& thead tr th":{borderBottom:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3]}`},"& tfoot tr th":{borderTop:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3]}`},"& tbody tr td":{padding:`${e.fn.size({size:n,sizes:e.spacing})}px ${e.fn.size({size:r,sizes:e.spacing})}px`,borderBottom:`1px solid ${e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3]}`,fontSize:e.fn.size({size:o,sizes:e.fontSizes})},"& tbody tr:last-of-type td":{borderBottom:"none"},"&[data-striped] tbody tr:nth-of-type(odd)":{backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[0]},"&[data-hover] tbody tr":e.fn.hover({backgroundColor:e.colorScheme==="dark"?e.colors.dark[5]:e.colors.gray[1]})})})),F8=L8,A8=Object.defineProperty,V8=Object.defineProperties,H8=Object.getOwnPropertyDescriptors,ys=Object.getOwnPropertySymbols,cb=Object.prototype.hasOwnProperty,fb=Object.prototype.propertyIsEnumerable,zh=(e,t,r)=>t in e?A8(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,B8=(e,t)=>{for(var r in t||(t={}))cb.call(t,r)&&zh(e,r,t[r]);if(ys)for(var r of ys(t))fb.call(t,r)&&zh(e,r,t[r]);return e},W8=(e,t)=>V8(e,H8(t)),U8=(e,t)=>{var r={};for(var n in e)cb.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&ys)for(var n of ys(e))t.indexOf(n)<0&&fb.call(e,n)&&(r[n]=e[n]);return r};const G8={striped:!1,highlightOnHover:!1,captionSide:"top",horizontalSpacing:"xs",fontSize:"sm",verticalSpacing:7},db=g.exports.forwardRef((e,t)=>{const r=ee("Table",G8,e),{className:n,children:o,striped:i,highlightOnHover:l,captionSide:a,horizontalSpacing:s,verticalSpacing:u,fontSize:c,unstyled:f}=r,d=U8(r,["className","children","striped","highlightOnHover","captionSide","horizontalSpacing","verticalSpacing","fontSize","unstyled"]),{classes:p,cx:y}=F8({captionSide:a,verticalSpacing:u,horizontalSpacing:s,fontSize:c},{unstyled:f,name:"Table"});return S(q,{...W8(B8({},d),{component:"table",ref:t,className:y(p.root,n),"data-striped":i||void 0,"data-hover":l||void 0}),children:o})});db.displayName="@mantine/core/Table";const Sf={context:"Tabs component was not found in the tree",value:"Tabs.Tab or Tabs.Panel component was rendered with invalid value or without value"},[Y8,op]=Id(Sf.context);var X8=Object.defineProperty,Dh=Object.getOwnPropertySymbols,q8=Object.prototype.hasOwnProperty,K8=Object.prototype.propertyIsEnumerable,Th=(e,t,r)=>t in e?X8(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Q8=(e,t)=>{for(var r in t||(t={}))q8.call(t,r)&&Th(e,r,t[r]);if(Dh)for(var r of Dh(t))K8.call(t,r)&&Th(e,r,t[r]);return e};function Z8({variant:e,orientation:t,inverted:r},n){const o=t==="vertical";return e==="default"?{[o?"borderRight":r?"borderTop":"borderBottom"]:`2px solid ${n.colorScheme==="dark"?n.colors.dark[4]:n.colors.gray[3]}`}:e==="outline"?{[o?"borderRight":r?"borderTop":"borderBottom"]:`1px solid ${n.colorScheme==="dark"?n.colors.dark[4]:n.colors.gray[3]}`}:e==="pills"?{gap:n.spacing.sm/2}:{}}var J8=Q((e,t)=>{const r=t.orientation==="vertical";return{tabsList:Q8({display:"flex",flexDirection:r?"column":"row",justifyContent:eS[t.position],'& [role="tab"]':{flex:t.grow?1:void 0}},Z8(t,e))}}),eN=J8,tN=Object.defineProperty,rN=Object.defineProperties,nN=Object.getOwnPropertyDescriptors,ws=Object.getOwnPropertySymbols,pb=Object.prototype.hasOwnProperty,gb=Object.prototype.propertyIsEnumerable,Mh=(e,t,r)=>t in e?tN(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,oN=(e,t)=>{for(var r in t||(t={}))pb.call(t,r)&&Mh(e,r,t[r]);if(ws)for(var r of ws(t))gb.call(t,r)&&Mh(e,r,t[r]);return e},iN=(e,t)=>rN(e,nN(t)),lN=(e,t)=>{var r={};for(var n in e)pb.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&ws)for(var n of ws(e))t.indexOf(n)<0&&gb.call(e,n)&&(r[n]=e[n]);return r};const mb=g.exports.forwardRef((e,t)=>{var r=e,{children:n,className:o,grow:i=!1,position:l="left"}=r,a=lN(r,["children","className","grow","position"]);const{orientation:s,variant:u,color:c,radius:f,inverted:d}=op(),{classNames:p,styles:y,unstyled:w}=dn(),{classes:v,cx:m}=eN({orientation:s,grow:i,variant:u,color:c,position:l,radius:f,inverted:d},{name:"Tabs",unstyled:w,classNames:p,styles:y});return S(q,{...iN(oN({},a),{className:m(v.tabsList,o),ref:t,role:"tablist","aria-orientation":s}),children:n})});mb.displayName="@mantine/core/TabsList";var aN=Q((e,{orientation:t})=>({panel:{flex:t==="vertical"?1:void 0}})),sN=aN,uN=Object.defineProperty,cN=Object.defineProperties,fN=Object.getOwnPropertyDescriptors,_s=Object.getOwnPropertySymbols,vb=Object.prototype.hasOwnProperty,hb=Object.prototype.propertyIsEnumerable,jh=(e,t,r)=>t in e?uN(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,dN=(e,t)=>{for(var r in t||(t={}))vb.call(t,r)&&jh(e,r,t[r]);if(_s)for(var r of _s(t))hb.call(t,r)&&jh(e,r,t[r]);return e},pN=(e,t)=>cN(e,fN(t)),gN=(e,t)=>{var r={};for(var n in e)vb.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&_s)for(var n of _s(e))t.indexOf(n)<0&&hb.call(e,n)&&(r[n]=e[n]);return r};const yb=g.exports.forwardRef((e,t)=>{var r=e,{value:n,children:o,sx:i,className:l}=r,a=gN(r,["value","children","sx","className"]);const s=op(),{classNames:u,styles:c,unstyled:f}=dn(),{classes:d,cx:p}=sN({orientation:s.orientation,variant:s.variant,color:s.color,radius:s.radius,inverted:s.inverted},{name:"Tabs",unstyled:f,classNames:u,styles:c});return S(q,{...pN(dN({},a),{ref:t,sx:[{display:s.value!==n?"none":void 0},...Si(i)],className:p(d.panel,l),role:"tabpanel",id:s.getPanelId(n),"aria-labelledby":s.getTabId(n)}),children:o})});yb.displayName="@mantine/core/TabsPanel";var mN=Object.defineProperty,vN=Object.defineProperties,hN=Object.getOwnPropertyDescriptors,Lh=Object.getOwnPropertySymbols,yN=Object.prototype.hasOwnProperty,wN=Object.prototype.propertyIsEnumerable,Fh=(e,t,r)=>t in e?mN(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,In=(e,t)=>{for(var r in t||(t={}))yN.call(t,r)&&Fh(e,r,t[r]);if(Lh)for(var r of Lh(t))wN.call(t,r)&&Fh(e,r,t[r]);return e},Ah=(e,t)=>vN(e,hN(t));function _N(e,{variant:t,orientation:r,color:n,radius:o,inverted:i}){const l=r==="vertical",a=e.fn.variant({color:n,variant:"filled"}),s=e.fn.radius(o),u=r==="vertical"?`${s}px 0 0 ${s}px`:i?`0 0 ${s}px ${s}px`:`${s}px ${s}px 0 0`;return t==="default"?Ah(In({[l?"borderRight":i?"borderTop":"borderBottom"]:"2px solid transparent",[l?"marginRight":i?"marginTop":"marginBottom"]:-2,borderRadius:u},e.fn.hover({backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[0],borderColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3]})),{"&[data-active]":In({borderColor:a.background,color:e.colorScheme==="dark"?e.white:e.black},e.fn.hover({borderColor:a.background}))}):t==="outline"?{borderRadius:u,border:"1px solid transparent",[l?"borderRight":i?"borderTop":"borderBottom"]:"none","&[data-active]":{borderColor:e.colorScheme==="dark"?e.colors.dark[4]:e.colors.gray[3],"&::before":{content:'""',backgroundColor:e.colorScheme==="dark"?e.colors.dark[7]:e.white,position:"absolute",bottom:l?0:i?"unset":-1,top:l?0:i?-1:"unset",[l?"width":"height"]:1,right:l?-1:0,left:l?"unset":0}}}:t==="pills"?Ah(In({borderRadius:e.fn.radius(o)},e.fn.hover({backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[0]})),{"&[data-active]":In({backgroundColor:a.background,color:e.white},e.fn.hover({backgroundColor:a.background}))}):{}}var SN=Q((e,t)=>({tabLabel:{},tab:In({position:"relative",padding:`${e.spacing.xs}px ${e.spacing.md}px`,paddingLeft:t.withIcon?e.spacing.xs:void 0,paddingRight:t.withRightSection?e.spacing.xs:void 0,fontSize:e.fontSizes.sm,whiteSpace:"nowrap",zIndex:0,display:"flex",alignItems:"center",justifyContent:t.orientation==="horizontal"?"center":void 0,lineHeight:1,"&:disabled":In({opacity:.5,cursor:"not-allowed"},e.fn.hover({backgroundColor:"transparent"})),"&:focus":{zIndex:1}},_N(e,t)),tabRightSection:{display:"flex",justifyContent:"center",alignItems:"center","&:not(:only-child)":{marginLeft:7}},tabIcon:{display:"flex",justifyContent:"center",alignItems:"center","&:not(:only-child)":{marginRight:7}}})),bN=SN,xN=Object.defineProperty,PN=Object.defineProperties,$N=Object.getOwnPropertyDescriptors,Ss=Object.getOwnPropertySymbols,wb=Object.prototype.hasOwnProperty,_b=Object.prototype.propertyIsEnumerable,Vh=(e,t,r)=>t in e?xN(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,ON=(e,t)=>{for(var r in t||(t={}))wb.call(t,r)&&Vh(e,r,t[r]);if(Ss)for(var r of Ss(t))_b.call(t,r)&&Vh(e,r,t[r]);return e},CN=(e,t)=>PN(e,$N(t)),EN=(e,t)=>{var r={};for(var n in e)wb.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Ss)for(var n of Ss(e))t.indexOf(n)<0&&_b.call(e,n)&&(r[n]=e[n]);return r};const Sb=g.exports.forwardRef((e,t)=>{var r=e,{value:n,children:o,onKeyDown:i,onClick:l,className:a,icon:s,rightSection:u,color:c}=r,f=EN(r,["value","children","onKeyDown","onClick","className","icon","rightSection","color"]);const d=op(),{classNames:p,styles:y,unstyled:w}=dn(),v=!!s,m=!!u,{theme:h,classes:_,cx:b}=bN({withIcon:v||m&&!o,withRightSection:m||v&&!o,orientation:d.orientation,color:c||d.color,variant:d.variant,radius:d.radius,inverted:d.inverted},{name:"Tabs",unstyled:w,classNames:p,styles:y}),O=n===d.value,x=P=>{d.onTabChange(d.allowTabDeactivation&&n===d.value?null:n),l?.(P)};return U(ou,{...CN(ON({},f),{unstyled:w,className:b(_.tab,a),"data-active":O||void 0,ref:t,type:"button",role:"tab",id:d.getTabId(n),"aria-selected":O,tabIndex:O||d.value===null?0:-1,"aria-controls":d.getPanelId(n),onClick:x,onKeyDown:g1({siblingSelector:'[role="tab"]',parentSelector:'[role="tablist"]',activateOnFocus:d.activateTabWithKeyboard,loop:d.loop,dir:h.dir,orientation:d.orientation,onKeyDown:i})}),children:[s&&S("div",{className:_.tabIcon,children:s}),o&&S("div",{className:_.tabLabel,children:o}),u&&S("div",{className:_.tabRightSection,children:u})]})});Sb.displayName="@mantine/core/Tab";function bb({defaultValue:e,value:t,onTabChange:r,orientation:n,children:o,loop:i,id:l,activateTabWithKeyboard:a,allowTabDeactivation:s,variant:u,color:c,radius:f,inverted:d}){const p=lo(l),[y,w]=Li({value:t,defaultValue:e,finalValue:null,onChange:r});return E.createElement(Y8,{value:{value:y,orientation:n,id:p,loop:i,activateTabWithKeyboard:a,getTabId:Tg(`${p}-tab`,Sf.value),getPanelId:Tg(`${p}-panel`,Sf.value),onTabChange:w,allowTabDeactivation:s,variant:u,color:c,radius:f,inverted:d}},o)}bb.displayName="@mantine/core/TabsProvider";var kN=Q((e,{orientation:t})=>({root:{display:t==="vertical"?"flex":void 0}})),RN=kN,IN=Object.defineProperty,NN=Object.defineProperties,zN=Object.getOwnPropertyDescriptors,bs=Object.getOwnPropertySymbols,xb=Object.prototype.hasOwnProperty,Pb=Object.prototype.propertyIsEnumerable,Hh=(e,t,r)=>t in e?IN(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,DN=(e,t)=>{for(var r in t||(t={}))xb.call(t,r)&&Hh(e,r,t[r]);if(bs)for(var r of bs(t))Pb.call(t,r)&&Hh(e,r,t[r]);return e},TN=(e,t)=>NN(e,zN(t)),MN=(e,t)=>{var r={};for(var n in e)xb.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&bs)for(var n of bs(e))t.indexOf(n)<0&&Pb.call(e,n)&&(r[n]=e[n]);return r};const jN={orientation:"horizontal",loop:!0,activateTabWithKeyboard:!0,allowTabDeactivation:!1,unstyled:!1,inverted:!1,variant:"default"},Je=g.exports.forwardRef((e,t)=>{const r=ee("Tabs",jN,e),{defaultValue:n,value:o,orientation:i,loop:l,activateTabWithKeyboard:a,allowTabDeactivation:s,children:u,id:c,onTabChange:f,variant:d,color:p,className:y,unstyled:w,classNames:v,styles:m,radius:h,inverted:_}=r,b=MN(r,["defaultValue","value","orientation","loop","activateTabWithKeyboard","allowTabDeactivation","children","id","onTabChange","variant","color","className","unstyled","classNames","styles","radius","inverted"]),{classes:O,cx:x}=RN({orientation:i,color:p,variant:d,radius:h,inverted:_},{unstyled:w,name:"Tabs",classNames:v,styles:m});return S(V1,{classNames:v,styles:m,unstyled:w,children:S(bb,{activateTabWithKeyboard:a,defaultValue:n,orientation:i,onTabChange:f,value:o,id:c,loop:l,allowTabDeactivation:s,color:p,variant:d,radius:h,inverted:_,children:S(q,{...TN(DN({},b),{className:x(O.root,y),id:c,ref:t}),children:u})})})});Je.List=mb;Je.Tab=Sb;Je.Panel=yb;Je.displayName="@mantine/core/Tabs";var LN=Object.defineProperty,FN=Object.defineProperties,AN=Object.getOwnPropertyDescriptors,Bh=Object.getOwnPropertySymbols,VN=Object.prototype.hasOwnProperty,HN=Object.prototype.propertyIsEnumerable,Wh=(e,t,r)=>t in e?LN(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,BN=(e,t)=>{for(var r in t||(t={}))VN.call(t,r)&&Wh(e,r,t[r]);if(Bh)for(var r of Bh(t))HN.call(t,r)&&Wh(e,r,t[r]);return e},WN=(e,t)=>FN(e,AN(t));const UN={xs:16,sm:20,md:26,lg:32,xl:40};var GN=Q((e,{color:t,size:r,radius:n,gradient:o,variant:i})=>{const l=e.fn.variant({variant:i,color:t||e.primaryColor,gradient:o,primaryFallback:!1}),a=e.fn.size({size:r,sizes:UN});return{root:WN(BN({},e.fn.fontStyles()),{display:"inline-flex",alignItems:"center",justifyContent:"center",boxSizing:"border-box",width:a,height:a,minWidth:a,minHeight:a,borderRadius:e.fn.radius(n),backgroundColor:l.background,color:l.color,backgroundImage:i==="gradient"?l.background:void 0,border:`${i==="gradient"?0:1}px solid ${l.border}`})}}),YN=GN,XN=Object.defineProperty,xs=Object.getOwnPropertySymbols,$b=Object.prototype.hasOwnProperty,Ob=Object.prototype.propertyIsEnumerable,Uh=(e,t,r)=>t in e?XN(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,qN=(e,t)=>{for(var r in t||(t={}))$b.call(t,r)&&Uh(e,r,t[r]);if(xs)for(var r of xs(t))Ob.call(t,r)&&Uh(e,r,t[r]);return e},KN=(e,t)=>{var r={};for(var n in e)$b.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&xs)for(var n of xs(e))t.indexOf(n)<0&&Ob.call(e,n)&&(r[n]=e[n]);return r};const QN={size:"md",variant:"filled",gradient:{from:"blue",to:"cyan",deg:45}},bf=g.exports.forwardRef((e,t)=>{const r=ee("ThemeIcon",QN,e),{className:n,size:o,radius:i,variant:l,color:a,children:s,gradient:u,unstyled:c}=r,f=KN(r,["className","size","radius","variant","color","children","gradient","unstyled"]),{classes:d,cx:p}=YN({variant:l,radius:i,color:a,size:o,gradient:u},{name:"ThemeIcon",unstyled:c});return S(q,{...qN({className:p(d.root,n),ref:t},f),children:s})});bf.displayName="@mantine/core/ThemeIcon";const Cb=g.exports.createContext(!1),ZN=Cb.Provider,JN=()=>g.exports.useContext(Cb);function Eb({children:e,openDelay:t=0,closeDelay:r=0}){return E.createElement(ZN,{value:!0},E.createElement(M3,{delay:{open:t,close:r}},e))}Eb.displayName="@mantine/core/TooltipGroup";var ez=Object.defineProperty,tz=Object.defineProperties,rz=Object.getOwnPropertyDescriptors,Gh=Object.getOwnPropertySymbols,nz=Object.prototype.hasOwnProperty,oz=Object.prototype.propertyIsEnumerable,Yh=(e,t,r)=>t in e?ez(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Xh=(e,t)=>{for(var r in t||(t={}))nz.call(t,r)&&Yh(e,r,t[r]);if(Gh)for(var r of Gh(t))oz.call(t,r)&&Yh(e,r,t[r]);return e},iz=(e,t)=>tz(e,rz(t));function lz(e,t){if(!t)return{backgroundColor:e.colorScheme==="dark"?e.colors.dark[6]:e.colors.gray[9],color:e.white};const r=e.fn.variant({variant:"filled",color:t,primaryFallback:!1});return{backgroundColor:r.background,color:r.color}}var az=Q((e,{color:t,radius:r,width:n,multiline:o})=>({tooltip:iz(Xh(Xh({},e.fn.fontStyles()),lz(e,t)),{lineHeight:e.lineHeight,fontSize:e.fontSizes.sm,borderRadius:e.fn.radius(r),padding:`${e.spacing.xs/2}px ${e.spacing.xs}px`,position:"absolute",whiteSpace:o?"unset":"nowrap",pointerEvents:"none",width:n}),arrow:{backgroundColor:"inherit",border:0,zIndex:1}})),kb=az;const Rb={children:"Tooltip component children should be an element or a component that accepts ref, fragments, strings, numbers and other primitive values are not supported"};function sz({offset:e,position:t}){const[r,n]=g.exports.useState(!1),o=g.exports.useRef(),{x:i,y:l,reference:a,floating:s,refs:u,update:c,placement:f}=Kd({placement:t,middleware:[Yd({crossAxis:!0,padding:5,rootBoundary:"document"})]}),d=f.includes("right")?e:t.includes("left")?e*-1:0,p=f.includes("bottom")?e:t.includes("top")?e*-1:0,y=g.exports.useCallback(({clientX:w,clientY:v})=>{a({getBoundingClientRect(){return{width:0,height:0,x:w,y:v,left:w+d,top:v+p,right:w,bottom:v}}})},[a]);return g.exports.useEffect(()=>{if(u.floating.current){const w=o.current;w.addEventListener("mousemove",y);const v=ln(u.floating.current);return v.forEach(m=>{m.addEventListener("scroll",c)}),()=>{w.removeEventListener("mousemove",y),v.forEach(m=>{m.removeEventListener("scroll",c)})}}},[a,u.floating,c,y,r]),{handleMouseMove:y,x:i,y:l,opened:r,setOpened:n,boundaryRef:o,floating:s}}var uz=Object.defineProperty,cz=Object.defineProperties,fz=Object.getOwnPropertyDescriptors,Ps=Object.getOwnPropertySymbols,Ib=Object.prototype.hasOwnProperty,Nb=Object.prototype.propertyIsEnumerable,qh=(e,t,r)=>t in e?uz(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,fc=(e,t)=>{for(var r in t||(t={}))Ib.call(t,r)&&qh(e,r,t[r]);if(Ps)for(var r of Ps(t))Nb.call(t,r)&&qh(e,r,t[r]);return e},dc=(e,t)=>cz(e,fz(t)),dz=(e,t)=>{var r={};for(var n in e)Ib.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Ps)for(var n of Ps(e))t.indexOf(n)<0&&Nb.call(e,n)&&(r[n]=e[n]);return r};const pz={refProp:"ref",withinPortal:!0,offset:10,position:"right",zIndex:io("popover")};function zb(e){var t;const r=ee("TooltipFloating",pz,e),{children:n,refProp:o,withinPortal:i,style:l,className:a,classNames:s,styles:u,unstyled:c,radius:f,color:d,label:p,offset:y,position:w,multiline:v,width:m,zIndex:h,disabled:_}=r,b=dz(r,["children","refProp","withinPortal","style","className","classNames","styles","unstyled","radius","color","label","offset","position","multiline","width","zIndex","disabled"]),{handleMouseMove:O,x,y:P,opened:$,boundaryRef:C,floating:I,setOpened:z}=sz({offset:y,position:w}),{classes:D,cx:j}=kb({radius:f,color:d,multiline:v,width:m},{name:"Tooltip",classNames:s,styles:u,unstyled:c});if(!Ti(n))throw new Error(Rb.children);const B=pn(C,n.ref),V=re=>{var se,ie;(ie=(se=n.props).onMouseEnter)==null||ie.call(se,re),O(re),z(!0)},W=re=>{var se,ie;(ie=(se=n.props).onMouseLeave)==null||ie.call(se,re),z(!1)};return U(it,{children:[S(Fi,{withinPortal:i,children:S(q,{...dc(fc({},b),{ref:I,className:j(D.tooltip,a),style:dc(fc({},l),{zIndex:h,display:$&&!_?"block":"none",top:P??"",left:(t=Math.round(x))!=null?t:""})}),children:p})}),g.exports.cloneElement(n,dc(fc({},n.props),{[o]:B,onMouseEnter:V,onMouseLeave:W}))]})}zb.displayName="@mantine/core/TooltipFloating";function gz(e){const[t,r]=g.exports.useState(!1),o=typeof e.opened=="boolean"?e.opened:t,i=JN(),l=lo(),{delay:a,currentId:s,setCurrentId:u}=u_(),c=g.exports.useCallback(x=>{r(x),x&&u(l)},[u,l]),{x:f,y:d,reference:p,floating:y,context:w,refs:v,update:m,placement:h}=Kd({placement:e.position,open:o,onOpenChange:c,middleware:[Qw(e.offset),Yd({padding:8}),Kw()]}),{getReferenceProps:_,getFloatingProps:b}=N3([T3(w,{enabled:e.events.hover,delay:i?a:{open:e.openDelay,close:e.closeDelay},mouseOnly:!e.events.touch}),A3(w,{enabled:e.events.focus,keyboardOnly:!0}),L3(w,{role:"tooltip"}),F3(w,{enabled:typeof e.opened===void 0}),j3(w,{id:l})]);return c_({opened:o,positionDependencies:e.positionDependencies,floating:{refs:v,update:m}}),kr(()=>{var x;(x=e.onPositionChange)==null||x.call(e,h)},[h]),{x:f,y:d,reference:p,floating:y,getFloatingProps:b,getReferenceProps:_,isGroupPhase:o&&s&&s!==l,opened:o,placement:h}}var mz=Object.defineProperty,vz=Object.defineProperties,hz=Object.getOwnPropertyDescriptors,$s=Object.getOwnPropertySymbols,Db=Object.prototype.hasOwnProperty,Tb=Object.prototype.propertyIsEnumerable,Kh=(e,t,r)=>t in e?mz(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Mo=(e,t)=>{for(var r in t||(t={}))Db.call(t,r)&&Kh(e,r,t[r]);if($s)for(var r of $s(t))Tb.call(t,r)&&Kh(e,r,t[r]);return e},yz=(e,t)=>vz(e,hz(t)),wz=(e,t)=>{var r={};for(var n in e)Db.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&$s)for(var n of $s(e))t.indexOf(n)<0&&Tb.call(e,n)&&(r[n]=e[n]);return r};const _z={position:"top",refProp:"ref",withinPortal:!1,arrowSize:4,arrowOffset:5,offset:5,transition:"fade",transitionDuration:100,width:"auto",events:{hover:!0,focus:!1,touch:!1},zIndex:io("popover"),positionDependencies:[]},vu=g.exports.forwardRef((e,t)=>{const r=ee("Tooltip",_z,e),{children:n,position:o,refProp:i,label:l,openDelay:a,closeDelay:s,onPositionChange:u,opened:c,withinPortal:f,radius:d,color:p,classNames:y,styles:w,unstyled:v,style:m,className:h,withArrow:_,arrowSize:b,arrowOffset:O,offset:x,transition:P,transitionDuration:$,multiline:C,width:I,events:z,zIndex:D,disabled:j,positionDependencies:B,onClick:V,onMouseEnter:W,onMouseLeave:re}=r,se=wz(r,["children","position","refProp","label","openDelay","closeDelay","onPositionChange","opened","withinPortal","radius","color","classNames","styles","unstyled","style","className","withArrow","arrowSize","arrowOffset","offset","transition","transitionDuration","multiline","width","events","zIndex","disabled","positionDependencies","onClick","onMouseEnter","onMouseLeave"]),{classes:ie,cx:Ne,theme:R}=kb({radius:d,color:p,width:I,multiline:C},{name:"Tooltip",classNames:y,styles:w,unstyled:v}),T=gz({position:P_(R.dir,o),closeDelay:s,openDelay:a,onPositionChange:u,opened:c,events:z,offset:x+(_?b/2:0),positionDependencies:[...B,n]});if(!Ti(n))throw new Error(Rb.children);const A=pn(T.reference,n.ref,t);return U(it,{children:[S(Fi,{withinPortal:f,children:S(pu,{mounted:!j&&T.opened,transition:P,duration:T.isGroupPhase?10:$,children:k=>{var M,G;return U(q,{...Mo(Mo({},se),T.getFloatingProps({ref:T.floating,className:ie.tooltip,style:yz(Mo(Mo({},m),k),{zIndex:D,top:(M=T.y)!=null?M:"",left:(G=T.x)!=null?G:""})})),children:[l,S(Qd,{visible:_,withBorder:!1,position:T.placement,arrowSize:b,arrowOffset:O,className:ie.arrow})]})}})}),g.exports.cloneElement(n,T.getReferenceProps(Mo({onClick:V,onMouseEnter:W,onMouseLeave:re,[i]:A,className:Ne(h,n.props.className)},n.props)))]})});vu.Group=Eb;vu.Floating=zb;vu.displayName="@mantine/core/Tooltip";const nt=vu;function Os(){return Os=Object.assign||function(e){for(var t=1;t=0&&(t.hash=e.substr(r),e=e.substr(0,r));var n=e.indexOf("?");n>=0&&(t.search=e.substr(n),e=e.substr(0,n)),e&&(t.pathname=e)}return t}/** + * React Router v6.3.0 + * + * Copyright (c) Remix Software Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */const Mb=g.exports.createContext(null),ip=g.exports.createContext(null),lp=g.exports.createContext({outlet:null,matches:[]});function Jt(e,t){if(!e)throw new Error(t)}function $z(e,t,r){r===void 0&&(r="/");let n=typeof t=="string"?an(t):t,o=Lb(n.pathname||"/",r);if(o==null)return null;let i=jb(e);Oz(i);let l=null;for(let a=0;l==null&&a{let l={relativePath:o.path||"",caseSensitive:o.caseSensitive===!0,childrenIndex:i,route:o};l.relativePath.startsWith("/")&&(l.relativePath.startsWith(n)||Jt(!1),l.relativePath=l.relativePath.slice(n.length));let a=tn([n,l.relativePath]),s=r.concat(l);o.children&&o.children.length>0&&(o.index===!0&&Jt(!1),jb(o.children,t,s,a)),!(o.path==null&&!o.index)&&t.push({path:a,score:zz(a,o.index),routesMeta:s})}),t}function Oz(e){e.sort((t,r)=>t.score!==r.score?r.score-t.score:Dz(t.routesMeta.map(n=>n.childrenIndex),r.routesMeta.map(n=>n.childrenIndex)))}const Cz=/^:\w+$/,Ez=3,kz=2,Rz=1,Iz=10,Nz=-2,t0=e=>e==="*";function zz(e,t){let r=e.split("/"),n=r.length;return r.some(t0)&&(n+=Nz),t&&(n+=kz),r.filter(o=>!t0(o)).reduce((o,i)=>o+(Cz.test(i)?Ez:i===""?Rz:Iz),n)}function Dz(e,t){return e.length===t.length&&e.slice(0,-1).every((n,o)=>n===t[o])?e[e.length-1]-t[t.length-1]:0}function Tz(e,t){let{routesMeta:r}=e,n={},o="/",i=[];for(let l=0;l{if(c==="*"){let d=a[f]||"";l=i.slice(0,i.length-d.length).replace(/(.)\/+$/,"$1")}return u[c]=Lz(a[f]||""),u},{}),pathname:i,pathnameBase:l,pattern:e}}function jz(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!0);let n=[],o="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^$?{}|()[\]]/g,"\\$&").replace(/:(\w+)/g,(l,a)=>(n.push(a),"([^\\/]+)"));return e.endsWith("*")?(n.push("*"),o+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):o+=r?"\\/*$":"(?:(?=[.~-]|%[0-9A-F]{2})|\\b|\\/|$)",[new RegExp(o,t?void 0:"i"),n]}function Lz(e,t){try{return decodeURIComponent(e)}catch{return e}}function Fz(e,t){t===void 0&&(t="/");let{pathname:r,search:n="",hash:o=""}=typeof e=="string"?an(e):e;return{pathname:r?r.startsWith("/")?r:Az(r,t):t,search:Hz(n),hash:Bz(o)}}function Az(e,t){let r=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(o=>{o===".."?r.length>1&&r.pop():o!=="."&&r.push(o)}),r.length>1?r.join("/"):"/"}function Vz(e,t,r){let n=typeof e=="string"?an(e):e,o=e===""||n.pathname===""?"/":n.pathname,i;if(o==null)i=r;else{let a=t.length-1;if(o.startsWith("..")){let s=o.split("/");for(;s[0]==="..";)s.shift(),a-=1;n.pathname=s.join("/")}i=a>=0?t[a]:"/"}let l=Fz(n,i);return o&&o!=="/"&&o.endsWith("/")&&!l.pathname.endsWith("/")&&(l.pathname+="/"),l}function Lb(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let r=e.charAt(t.length);return r&&r!=="/"?null:e.slice(t.length)||"/"}const tn=e=>e.join("/").replace(/\/\/+/g,"/"),Fb=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),Hz=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,Bz=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function hu(){return g.exports.useContext(ip)!=null}function ap(){return hu()||Jt(!1),g.exports.useContext(ip).location}function Bi(){hu()||Jt(!1);let{basename:e,navigator:t}=g.exports.useContext(Mb),{matches:r}=g.exports.useContext(lp),{pathname:n}=ap(),o=JSON.stringify(r.map(a=>a.pathnameBase)),i=g.exports.useRef(!1);return g.exports.useEffect(()=>{i.current=!0}),g.exports.useCallback(function(a,s){if(s===void 0&&(s={}),!i.current)return;if(typeof a=="number"){t.go(a);return}let u=Vz(a,JSON.parse(o),n);e!=="/"&&(u.pathname=tn([e,u.pathname])),(s.replace?t.replace:t.push)(u,s.state)},[e,t,o,n])}function Wz(e,t){hu()||Jt(!1);let{matches:r}=g.exports.useContext(lp),n=r[r.length-1],o=n?n.params:{};n&&n.pathname;let i=n?n.pathnameBase:"/";n&&n.route;let l=ap(),a;if(t){var s;let d=typeof t=="string"?an(t):t;i==="/"||((s=d.pathname)==null?void 0:s.startsWith(i))||Jt(!1),a=d}else a=l;let u=a.pathname||"/",c=i==="/"?u:u.slice(i.length)||"/",f=$z(e,{pathname:c});return Uz(f&&f.map(d=>Object.assign({},d,{params:Object.assign({},o,d.params),pathname:tn([i,d.pathname]),pathnameBase:d.pathnameBase==="/"?i:tn([i,d.pathnameBase])})),r)}function Uz(e,t){return t===void 0&&(t=[]),e==null?null:e.reduceRight((r,n,o)=>g.exports.createElement(lp.Provider,{children:n.route.element!==void 0?n.route.element:r,value:{outlet:r,matches:t.concat(e.slice(0,o+1))}}),null)}function Bt(e){Jt(!1)}function Gz(e){let{basename:t="/",children:r=null,location:n,navigationType:o=Zr.Pop,navigator:i,static:l=!1}=e;hu()&&Jt(!1);let a=Fb(t),s=g.exports.useMemo(()=>({basename:a,navigator:i,static:l}),[a,i,l]);typeof n=="string"&&(n=an(n));let{pathname:u="/",search:c="",hash:f="",state:d=null,key:p="default"}=n,y=g.exports.useMemo(()=>{let w=Lb(u,a);return w==null?null:{pathname:w,search:c,hash:f,state:d,key:p}},[a,u,c,f,d,p]);return y==null?null:g.exports.createElement(Mb.Provider,{value:s},g.exports.createElement(ip.Provider,{children:r,value:{location:y,navigationType:o}}))}function Ab(e){let{children:t,location:r}=e;return Wz(xf(t),r)}function xf(e){let t=[];return g.exports.Children.forEach(e,r=>{if(!g.exports.isValidElement(r))return;if(r.type===g.exports.Fragment){t.push.apply(t,xf(r.props.children));return}r.type!==Bt&&Jt(!1);let n={caseSensitive:r.props.caseSensitive,element:r.props.element,index:r.props.index,path:r.props.path};r.props.children&&(n.children=xf(r.props.children)),t.push(n)}),t}/** + * React Router DOM v6.3.0 + * + * Copyright (c) Remix Software Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */function Yz(e){let{basename:t,children:r,window:n}=e,o=g.exports.useRef();o.current==null&&(o.current=xz({window:n}));let i=o.current,[l,a]=g.exports.useState({action:i.action,location:i.location});return g.exports.useLayoutEffect(()=>i.listen(a),[i]),g.exports.createElement(Gz,{basename:t,children:r,location:l.location,navigationType:l.action,navigator:i})}const Xz=()=>!window.invokeNative,Vb=()=>{},Sl=(e,t)=>{const r=g.exports.useRef(Vb);g.exports.useEffect(()=>{r.current=t},[t]),g.exports.useEffect(()=>{const n=o=>{const{action:i,data:l}=o.data;r.current&&i===e&&r.current(l)};return window.addEventListener("message",n),()=>window.removeEventListener("message",n)},[e])};function qz(e){let t;const r=new Set,n=(u,c)=>{const f=typeof u=="function"?u(t):u;if(f!==t){const d=t;t=c?f:Object.assign({},t,f),r.forEach(p=>p(t,d))}},o=()=>t,i=(u,c=o,f=Object.is)=>{console.warn("[DEPRECATED] Please use `subscribeWithSelector` middleware");let d=c(t);function p(){const y=c(t);if(!f(d,y)){const w=d;u(d=y,w)}}return r.add(p),()=>r.delete(p)},s={setState:n,getState:o,subscribe:(u,c,f)=>c||f?i(u,c,f):(r.add(u),()=>r.delete(u)),destroy:()=>r.clear()};return t=e(n,o,s),s}const Kz=typeof window>"u"||!window.navigator||/ServerSideRendering|^Deno\//.test(window.navigator.userAgent),r0=Kz?g.exports.useEffect:g.exports.useLayoutEffect;function uo(e){const t=typeof e=="function"?qz(e):e,r=(n=t.getState,o=Object.is)=>{const[,i]=g.exports.useReducer(v=>v+1,0),l=t.getState(),a=g.exports.useRef(l),s=g.exports.useRef(n),u=g.exports.useRef(o),c=g.exports.useRef(!1),f=g.exports.useRef();f.current===void 0&&(f.current=n(l));let d,p=!1;(a.current!==l||s.current!==n||u.current!==o||c.current)&&(d=n(l),p=!o(f.current,d)),r0(()=>{p&&(f.current=d),a.current=l,s.current=n,u.current=o,c.current=!1});const y=g.exports.useRef(l);r0(()=>{const v=()=>{try{const h=t.getState(),_=s.current(h);u.current(f.current,_)||(a.current=h,f.current=_,i())}catch{c.current=!0,i()}},m=t.subscribe(v);return t.getState()!==y.current&&v(),m},[]);const w=p?d:f.current;return g.exports.useDebugValue(w),w};return Object.assign(r,t),r[Symbol.iterator]=function(){console.warn("[useStore, api] = create() is deprecated and will be removed in v4");const n=[r,t];return{next(){const o=n.length<=0;return{value:n.shift(),done:o}}}},r}const K=uo(()=>({name:"",passcode:"",autolock:0,items:[{name:"",metadata:"",remove:!1}],characters:[""],groups:[{name:"",grade:void 0}],lockpickDifficulty:[""],maxDistance:0,doorRate:0,lockSound:"",unlockSound:"",auto:!1,state:!1,lockpick:!1,hideUi:!1,doors:!1,holdOpen:!1})),Qz=K.getState(),_e=uo((e,t)=>({sounds:[""],setSounds:r=>e({sounds:r}),setLockSound:r=>K.setState({lockSound:r}),setUnlockSound:r=>K.setState({unlockSound:r}),setName:r=>K.setState({name:r}),setPasscode:r=>K.setState({passcode:r}),setAutolock:r=>K.setState({autolock:r}),toggleCheckbox:r=>K.setState(n=>({[r]:!n[r]})),setMaxDistance:r=>K.setState(()=>({maxDistance:r})),setItems:r=>K.setState(({items:n})=>({items:r(n)})),setCharacters:r=>K.setState(({characters:n})=>({characters:r(n)})),setGroups:r=>K.setState(({groups:n})=>({groups:r(n)})),setLockpickDifficulty:r=>K.setState(({lockpickDifficulty:n})=>({lockpickDifficulty:r(n)})),setDoorRate:r=>K.setState({doorRate:r})}));var Hb={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},n0=E.createContext&&E.createContext(Hb),br=globalThis&&globalThis.__assign||function(){return br=Object.assign||function(e){for(var t,r=1,n=arguments.length;r({visible:!1,setVisible:t=>e({visible:t})}));async function xr(e,t){const r={method:"post",headers:{"Content-Type":"application/json; charset=UTF-8"},body:JSON.stringify(t)},n=window.GetParentResourceName?window.GetParentResourceName():"nui-frame-app";return await(await fetch(`https://${n}/${e}`,r)).json()}function cD(e,t){const[r,n]=g.exports.useState(e);return g.exports.useEffect(()=>{const o=setTimeout(()=>n(e),t||500);return()=>{clearTimeout(o)}},[e,t]),r}const Pf=uo(e=>({value:"",debouncedValue:"",setDebouncedValue:t=>e({debouncedValue:t}),setValue:t=>e({value:t})})),fD=()=>{const e=Pf(),t=cD(e.value);return g.exports.useEffect(()=>{e.setDebouncedValue(t)},[t]),S(it,{children:S(Tr,{sx:{flex:"1 1 auto",padding:2},icon:S(Ub,{size:20}),placeholder:"Search",value:e.value??"",onChange:r=>e.setValue(r.target.value)})})},dD=Q({main:{display:"flex",justifyContent:"flex-start",alignItems:"center",padding:16,paddingBottom:0}}),pD=()=>{const{classes:e}=dD(),t=Bi(),r=wu(n=>n.setVisible);return U(jt,{className:e.main,children:[S(nt,{label:"Create a new door",transition:"pop",children:S($t,{variant:"light",color:"blue",size:"lg",onClick:()=>{K.setState(Qz,!0),t("/settings/general")},children:S(Wb,{size:20})})}),S(fD,{}),S(iu,{iconSize:20,size:"lg",onClick:()=>{r(!1),xr("exit")}})]})};/** + * react-table + * + * Copyright (c) TanStack + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + *//** + * table-core + * + * Copyright (c) TanStack + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */function dr(e,t){return typeof e=="function"?e(t):e}function vt(e,t){return r=>{t.setState(n=>({...n,[e]:dr(r,n[e])}))}}function Cs(e){return e instanceof Function}function gD(e,t){const r=[],n=o=>{o.forEach(i=>{r.push(i);const l=t(i);l!=null&&l.length&&n(l)})};return n(e),r}function X(e,t,r){let n=[],o;return()=>{let i;r.key&&r.debug&&(i=Date.now());const l=e();if(!(l.length!==n.length||l.some((u,c)=>n[c]!==u)))return o;n=l;let s;if(r.key&&r.debug&&(s=Date.now()),o=t(...l),r==null||r.onChange==null||r.onChange(o),r.key&&r.debug&&r!=null&&r.debug()){const u=Math.round((Date.now()-i)*100)/100,c=Math.round((Date.now()-s)*100)/100,f=c/16,d=(p,y)=>{for(p=String(p);p.length{let p=d;for(const y of s.split("."))p=p[y];return p}:c=d=>d[a.accessorKey]),!u)throw new Error;let f={id:""+String(u),accessorFn:c,parent:n,depth:r,columnDef:a,columns:[],getFlatColumns:X(()=>[!0],()=>{var d;return[f,...(d=f.columns)==null?void 0:d.flatMap(p=>p.getFlatColumns())]},{key:"column.getFlatColumns",debug:()=>{var d;return(d=e.options.debugAll)!=null?d:e.options.debugColumns}}),getLeafColumns:X(()=>[e._getOrderColumnsFn()],d=>{var p;if((p=f.columns)!=null&&p.length){let y=f.columns.flatMap(w=>w.getLeafColumns());return d(y)}return[f]},{key:"column.getLeafColumns",debug:()=>{var d;return(d=e.options.debugAll)!=null?d:e.options.debugColumns}})};return f=e._features.reduce((d,p)=>Object.assign(d,p.createColumn==null?void 0:p.createColumn(f,e)),f),f}function o0(e,t,r){var n;let i={id:(n=r.id)!=null?n:t.id,column:t,index:r.index,isPlaceholder:!!r.isPlaceholder,placeholderId:r.placeholderId,depth:r.depth,subHeaders:[],colSpan:0,rowSpan:0,headerGroup:null,getLeafHeaders:()=>{const l=[],a=s=>{s.subHeaders&&s.subHeaders.length&&s.subHeaders.map(a),l.push(s)};return a(i),l},getContext:()=>({table:e,header:i,column:t})};return e._features.forEach(l=>{Object.assign(i,l.createHeader==null?void 0:l.createHeader(i,e))}),i}const vD={createTable:e=>({getHeaderGroups:X(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,r,n,o)=>{var i,l;const a=(i=n?.map(f=>r.find(d=>d.id===f)).filter(Boolean))!=null?i:[],s=(l=o?.map(f=>r.find(d=>d.id===f)).filter(Boolean))!=null?l:[],u=r.filter(f=>!(n!=null&&n.includes(f.id))&&!(o!=null&&o.includes(f.id)));return bl(t,[...a,...u,...s],e)},{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugHeaders}}),getCenterHeaderGroups:X(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,r,n,o)=>(r=r.filter(i=>!(n!=null&&n.includes(i.id))&&!(o!=null&&o.includes(i.id))),bl(t,r,e,"center")),{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugHeaders}}),getLeftHeaderGroups:X(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.left],(t,r,n)=>{var o;const i=(o=n?.map(l=>r.find(a=>a.id===l)).filter(Boolean))!=null?o:[];return bl(t,i,e,"left")},{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugHeaders}}),getRightHeaderGroups:X(()=>[e.getAllColumns(),e.getVisibleLeafColumns(),e.getState().columnPinning.right],(t,r,n)=>{var o;const i=(o=n?.map(l=>r.find(a=>a.id===l)).filter(Boolean))!=null?o:[];return bl(t,i,e,"right")},{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugHeaders}}),getFooterGroups:X(()=>[e.getHeaderGroups()],t=>[...t].reverse(),{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugHeaders}}),getLeftFooterGroups:X(()=>[e.getLeftHeaderGroups()],t=>[...t].reverse(),{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugHeaders}}),getCenterFooterGroups:X(()=>[e.getCenterHeaderGroups()],t=>[...t].reverse(),{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugHeaders}}),getRightFooterGroups:X(()=>[e.getRightHeaderGroups()],t=>[...t].reverse(),{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugHeaders}}),getFlatHeaders:X(()=>[e.getHeaderGroups()],t=>t.map(r=>r.headers).flat(),{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugHeaders}}),getLeftFlatHeaders:X(()=>[e.getLeftHeaderGroups()],t=>t.map(r=>r.headers).flat(),{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugHeaders}}),getCenterFlatHeaders:X(()=>[e.getCenterHeaderGroups()],t=>t.map(r=>r.headers).flat(),{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugHeaders}}),getRightFlatHeaders:X(()=>[e.getRightHeaderGroups()],t=>t.map(r=>r.headers).flat(),{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugHeaders}}),getCenterLeafHeaders:X(()=>[e.getCenterFlatHeaders()],t=>t.filter(r=>{var n;return!((n=r.subHeaders)!=null&&n.length)}),{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugHeaders}}),getLeftLeafHeaders:X(()=>[e.getLeftFlatHeaders()],t=>t.filter(r=>{var n;return!((n=r.subHeaders)!=null&&n.length)}),{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugHeaders}}),getRightLeafHeaders:X(()=>[e.getRightFlatHeaders()],t=>t.filter(r=>{var n;return!((n=r.subHeaders)!=null&&n.length)}),{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugHeaders}}),getLeafHeaders:X(()=>[e.getLeftHeaderGroups(),e.getCenterHeaderGroups(),e.getRightHeaderGroups()],(t,r,n)=>{var o,i,l,a,s,u;return[...(o=(i=t[0])==null?void 0:i.headers)!=null?o:[],...(l=(a=r[0])==null?void 0:a.headers)!=null?l:[],...(s=(u=n[0])==null?void 0:u.headers)!=null?s:[]].map(c=>c.getLeafHeaders()).flat()},{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugHeaders}})})};function bl(e,t,r,n){var o,i;let l=0;const a=function(d,p){p===void 0&&(p=1),l=Math.max(l,p),d.filter(y=>y.getIsVisible()).forEach(y=>{var w;(w=y.columns)!=null&&w.length&&a(y.columns,p+1)},0)};a(e);let s=[];const u=(d,p)=>{const y={depth:p,id:[n,""+p].filter(Boolean).join("_"),headers:[]},w=[];d.forEach(v=>{const m=[...w].reverse()[0],h=v.column.depth===y.depth;let _,b=!1;if(h&&v.column.parent?_=v.column.parent:(_=v.column,b=!0),m&&m?.column===_)m.subHeaders.push(v);else{const O=o0(r,_,{id:[n,p,_.id,v?.id].filter(Boolean).join("_"),isPlaceholder:b,placeholderId:b?""+w.filter(x=>x.column===_).length:void 0,depth:p,index:w.length});O.subHeaders.push(v),w.push(O)}y.headers.push(v),v.headerGroup=y}),s.push(y),p>0&&u(w,p-1)},c=t.map((d,p)=>o0(r,d,{depth:l,index:p}));u(c,l-1),s.reverse();const f=d=>d.filter(y=>y.column.getIsVisible()).map(y=>{let w=0,v=0,m=[0];y.subHeaders&&y.subHeaders.length?(m=[],f(y.subHeaders).forEach(_=>{let{colSpan:b,rowSpan:O}=_;w+=b,m.push(O)})):w=1;const h=Math.min(...m);return v=v+h,y.colSpan=w,y.rowSpan=v,{colSpan:w,rowSpan:v}});return f((o=(i=s[0])==null?void 0:i.headers)!=null?o:[]),s}const xl={size:150,minSize:20,maxSize:Number.MAX_SAFE_INTEGER},gc=()=>({startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,isResizingColumn:!1,columnSizingStart:[]}),hD={getDefaultColumnDef:()=>xl,getInitialState:e=>({columnSizing:{},columnSizingInfo:gc(),...e}),getDefaultOptions:e=>({columnResizeMode:"onEnd",onColumnSizingChange:vt("columnSizing",e),onColumnSizingInfoChange:vt("columnSizingInfo",e)}),createColumn:(e,t)=>({getSize:()=>{var r,n,o;const i=t.getState().columnSizing[e.id];return Math.min(Math.max((r=e.columnDef.minSize)!=null?r:xl.minSize,(n=i??e.columnDef.size)!=null?n:xl.size),(o=e.columnDef.maxSize)!=null?o:xl.maxSize)},getStart:r=>{const n=r?r==="left"?t.getLeftVisibleLeafColumns():t.getRightVisibleLeafColumns():t.getVisibleLeafColumns(),o=n.findIndex(i=>i.id===e.id);if(o>0){const i=n[o-1];return i.getStart(r)+i.getSize()}return 0},resetSize:()=>{t.setColumnSizing(r=>{let{[e.id]:n,...o}=r;return o})},getCanResize:()=>{var r,n;return((r=e.columnDef.enableResizing)!=null?r:!0)&&((n=t.options.enableColumnResizing)!=null?n:!0)},getIsResizing:()=>t.getState().columnSizingInfo.isResizingColumn===e.id}),createHeader:(e,t)=>({getSize:()=>{let r=0;const n=o=>{if(o.subHeaders.length)o.subHeaders.forEach(n);else{var i;r+=(i=o.column.getSize())!=null?i:0}};return n(e),r},getStart:()=>{if(e.index>0){const r=e.headerGroup.headers[e.index-1];return r.getStart()+r.getSize()}return 0},getResizeHandler:()=>{const r=t.getColumn(e.column.id),n=r.getCanResize();return o=>{if(!n||(o.persist==null||o.persist(),mc(o)&&o.touches&&o.touches.length>1))return;const i=e.getSize(),l=e?e.getLeafHeaders().map(p=>[p.column.id,p.column.getSize()]):[[r.id,r.getSize()]],a=mc(o)?Math.round(o.touches[0].clientX):o.clientX,s=(p,y)=>{if(typeof y!="number")return;let w={};t.setColumnSizingInfo(v=>{var m,h;const _=y-((m=v?.startOffset)!=null?m:0),b=Math.max(_/((h=v?.startSize)!=null?h:0),-.999999);return v.columnSizingStart.forEach(O=>{let[x,P]=O;w[x]=Math.round(Math.max(P+P*b,0)*100)/100}),{...v,deltaOffset:_,deltaPercentage:b}}),(t.options.columnResizeMode==="onChange"||p==="end")&&t.setColumnSizing(v=>({...v,...w}))},u=p=>s("move",p),c=p=>{s("end",p),t.setColumnSizingInfo(y=>({...y,isResizingColumn:!1,startOffset:null,startSize:null,deltaOffset:null,deltaPercentage:null,columnSizingStart:[]}))},f={moveHandler:p=>u(p.clientX),upHandler:p=>{document.removeEventListener("mousemove",f.moveHandler),document.removeEventListener("mouseup",f.upHandler),c(p.clientX)}},d=yD()?{passive:!1}:!1;mc(o)||(document.addEventListener("mousemove",f.moveHandler,d),document.addEventListener("mouseup",f.upHandler,d)),t.setColumnSizingInfo(p=>({...p,startOffset:a,startSize:i,deltaOffset:0,deltaPercentage:0,columnSizingStart:l,isResizingColumn:r.id}))}}}),createTable:e=>({setColumnSizing:t=>e.options.onColumnSizingChange==null?void 0:e.options.onColumnSizingChange(t),setColumnSizingInfo:t=>e.options.onColumnSizingInfoChange==null?void 0:e.options.onColumnSizingInfoChange(t),resetColumnSizing:t=>{var r;e.setColumnSizing(t?{}:(r=e.initialState.columnSizing)!=null?r:{})},resetHeaderSizeInfo:t=>{var r;e.setColumnSizingInfo(t?gc():(r=e.initialState.columnSizingInfo)!=null?r:gc())},getTotalSize:()=>{var t,r;return(t=(r=e.getHeaderGroups()[0])==null?void 0:r.headers.reduce((n,o)=>n+o.getSize(),0))!=null?t:0},getLeftTotalSize:()=>{var t,r;return(t=(r=e.getLeftHeaderGroups()[0])==null?void 0:r.headers.reduce((n,o)=>n+o.getSize(),0))!=null?t:0},getCenterTotalSize:()=>{var t,r;return(t=(r=e.getCenterHeaderGroups()[0])==null?void 0:r.headers.reduce((n,o)=>n+o.getSize(),0))!=null?t:0},getRightTotalSize:()=>{var t,r;return(t=(r=e.getRightHeaderGroups()[0])==null?void 0:r.headers.reduce((n,o)=>n+o.getSize(),0))!=null?t:0}})};let Pl=null;function yD(){if(typeof Pl=="boolean")return Pl;let e=!1;try{const t={get passive(){return e=!0,!1}},r=()=>{};window.addEventListener("test",r,t),window.removeEventListener("test",r)}catch{e=!1}return Pl=e,Pl}function mc(e){return e.type==="touchstart"}const wD={getInitialState:e=>({expanded:{},...e}),getDefaultOptions:e=>({onExpandedChange:vt("expanded",e),paginateExpandedRows:!0}),createTable:e=>{let t=!1,r=!1;return{_autoResetExpanded:()=>{var n,o;if(!t){e._queue(()=>{t=!0});return}if((n=(o=e.options.autoResetAll)!=null?o:e.options.autoResetExpanded)!=null?n:!e.options.manualExpanding){if(r)return;r=!0,e._queue(()=>{e.resetExpanded(),r=!1})}},setExpanded:n=>e.options.onExpandedChange==null?void 0:e.options.onExpandedChange(n),toggleAllRowsExpanded:n=>{n??!e.getIsAllRowsExpanded()?e.setExpanded(!0):e.setExpanded({})},resetExpanded:n=>{var o,i;e.setExpanded(n?{}:(o=(i=e.initialState)==null?void 0:i.expanded)!=null?o:{})},getCanSomeRowsExpand:()=>e.getRowModel().flatRows.some(n=>n.getCanExpand()),getToggleAllRowsExpandedHandler:()=>n=>{n.persist==null||n.persist(),e.toggleAllRowsExpanded()},getIsSomeRowsExpanded:()=>{const n=e.getState().expanded;return n===!0||Object.values(n).some(Boolean)},getIsAllRowsExpanded:()=>{const n=e.getState().expanded;return typeof n=="boolean"?n===!0:!(!Object.keys(n).length||e.getRowModel().flatRows.some(o=>o.getIsExpanded()))},getExpandedDepth:()=>{let n=0;return(e.getState().expanded===!0?Object.keys(e.getRowModel().rowsById):Object.keys(e.getState().expanded)).forEach(i=>{const l=i.split(".");n=Math.max(n,l.length)}),n},getPreExpandedRowModel:()=>e.getSortedRowModel(),getExpandedRowModel:()=>(!e._getExpandedRowModel&&e.options.getExpandedRowModel&&(e._getExpandedRowModel=e.options.getExpandedRowModel(e)),e.options.manualExpanding||!e._getExpandedRowModel?e.getPreExpandedRowModel():e._getExpandedRowModel())}},createRow:(e,t)=>({toggleExpanded:r=>{t.setExpanded(n=>{var o;const i=n===!0?!0:!!(n!=null&&n[e.id]);let l={};if(n===!0?Object.keys(t.getRowModel().rowsById).forEach(a=>{l[a]=!0}):l=n,r=(o=r)!=null?o:!i,!i&&r)return{...l,[e.id]:!0};if(i&&!r){const{[e.id]:a,...s}=l;return s}return n})},getIsExpanded:()=>{var r;const n=t.getState().expanded;return!!((r=t.options.getIsRowExpanded==null?void 0:t.options.getIsRowExpanded(e))!=null?r:n===!0||n?.[e.id])},getCanExpand:()=>{var r,n,o;return(r=t.options.getRowCanExpand==null?void 0:t.options.getRowCanExpand(e))!=null?r:((n=t.options.enableExpanding)!=null?n:!0)&&!!((o=e.subRows)!=null&&o.length)},getToggleExpandedHandler:()=>{const r=e.getCanExpand();return()=>{!r||e.toggleExpanded()}}})},Gb=(e,t,r)=>{var n;const o=r.toLowerCase();return(n=e.getValue(t))==null?void 0:n.toLowerCase().includes(o)};Gb.autoRemove=e=>Pt(e);const Yb=(e,t,r)=>{var n;return(n=e.getValue(t))==null?void 0:n.includes(r)};Yb.autoRemove=e=>Pt(e);const Xb=(e,t,r)=>{var n;return((n=e.getValue(t))==null?void 0:n.toLowerCase())===r.toLowerCase()};Xb.autoRemove=e=>Pt(e);const qb=(e,t,r)=>{var n;return(n=e.getValue(t))==null?void 0:n.includes(r)};qb.autoRemove=e=>Pt(e)||!(e!=null&&e.length);const Kb=(e,t,r)=>!r.some(n=>{var o;return!((o=e.getValue(t))!=null&&o.includes(n))});Kb.autoRemove=e=>Pt(e)||!(e!=null&&e.length);const Qb=(e,t,r)=>r.some(n=>{var o;return(o=e.getValue(t))==null?void 0:o.includes(n)});Qb.autoRemove=e=>Pt(e)||!(e!=null&&e.length);const Zb=(e,t,r)=>e.getValue(t)===r;Zb.autoRemove=e=>Pt(e);const Jb=(e,t,r)=>e.getValue(t)==r;Jb.autoRemove=e=>Pt(e);const sp=(e,t,r)=>{let[n,o]=r;const i=e.getValue(t);return i>=n&&i<=o};sp.resolveFilterValue=e=>{let[t,r]=e,n=typeof t!="number"?parseFloat(t):t,o=typeof r!="number"?parseFloat(r):r,i=t===null||Number.isNaN(n)?-1/0:n,l=r===null||Number.isNaN(o)?1/0:o;if(i>l){const a=i;i=l,l=a}return[i,l]};sp.autoRemove=e=>Pt(e)||Pt(e[0])&&Pt(e[1]);const At={includesString:Gb,includesStringSensitive:Yb,equalsString:Xb,arrIncludes:qb,arrIncludesAll:Kb,arrIncludesSome:Qb,equals:Zb,weakEquals:Jb,inNumberRange:sp};function Pt(e){return e==null||e===""}const _D={getDefaultColumnDef:()=>({filterFn:"auto"}),getInitialState:e=>({columnFilters:[],globalFilter:void 0,...e}),getDefaultOptions:e=>({onColumnFiltersChange:vt("columnFilters",e),onGlobalFilterChange:vt("globalFilter",e),filterFromLeafRows:!1,globalFilterFn:"auto",getColumnCanGlobalFilter:t=>{var r,n;const o=(r=e.getCoreRowModel().flatRows[0])==null||(n=r._getAllCellsByColumnId()[t.id])==null?void 0:n.getValue();return typeof o=="string"||typeof o=="number"}}),createColumn:(e,t)=>({getAutoFilterFn:()=>{const r=t.getCoreRowModel().flatRows[0],n=r?.getValue(e.id);return typeof n=="string"?At.includesString:typeof n=="number"?At.inNumberRange:typeof n=="boolean"||n!==null&&typeof n=="object"?At.equals:Array.isArray(n)?At.arrIncludes:At.weakEquals},getFilterFn:()=>{var r,n;return Cs(e.columnDef.filterFn)?e.columnDef.filterFn:e.columnDef.filterFn==="auto"?e.getAutoFilterFn():(r=(n=t.options.filterFns)==null?void 0:n[e.columnDef.filterFn])!=null?r:At[e.columnDef.filterFn]},getCanFilter:()=>{var r,n,o;return((r=e.columnDef.enableColumnFilter)!=null?r:!0)&&((n=t.options.enableColumnFilters)!=null?n:!0)&&((o=t.options.enableFilters)!=null?o:!0)&&!!e.accessorFn},getCanGlobalFilter:()=>{var r,n,o,i;return((r=e.columnDef.enableGlobalFilter)!=null?r:!0)&&((n=t.options.enableGlobalFilter)!=null?n:!0)&&((o=t.options.enableFilters)!=null?o:!0)&&((i=t.options.getColumnCanGlobalFilter==null?void 0:t.options.getColumnCanGlobalFilter(e))!=null?i:!0)&&!!e.accessorFn},getIsFiltered:()=>e.getFilterIndex()>-1,getFilterValue:()=>{var r,n;return(r=t.getState().columnFilters)==null||(n=r.find(o=>o.id===e.id))==null?void 0:n.value},getFilterIndex:()=>{var r,n;return(r=(n=t.getState().columnFilters)==null?void 0:n.findIndex(o=>o.id===e.id))!=null?r:-1},setFilterValue:r=>{t.setColumnFilters(n=>{const o=e.getFilterFn(),i=n?.find(c=>c.id===e.id),l=dr(r,i?i.value:void 0);if(i0(o,l,e)){var a;return(a=n?.filter(c=>c.id!==e.id))!=null?a:[]}const s={id:e.id,value:l};if(i){var u;return(u=n?.map(c=>c.id===e.id?s:c))!=null?u:[]}return n!=null&&n.length?[...n,s]:[s]})},_getFacetedRowModel:t.options.getFacetedRowModel&&t.options.getFacetedRowModel(t,e.id),getFacetedRowModel:()=>e._getFacetedRowModel?e._getFacetedRowModel():t.getPreFilteredRowModel(),_getFacetedUniqueValues:t.options.getFacetedUniqueValues&&t.options.getFacetedUniqueValues(t,e.id),getFacetedUniqueValues:()=>e._getFacetedUniqueValues?e._getFacetedUniqueValues():new Map,_getFacetedMinMaxValues:t.options.getFacetedMinMaxValues&&t.options.getFacetedMinMaxValues(t,e.id),getFacetedMinMaxValues:()=>{if(!!e._getFacetedMinMaxValues)return e._getFacetedMinMaxValues()}}),createRow:(e,t)=>({columnFilters:{},columnFiltersMeta:{}}),createTable:e=>({getGlobalAutoFilterFn:()=>At.includesString,getGlobalFilterFn:()=>{var t,r;const{globalFilterFn:n}=e.options;return Cs(n)?n:n==="auto"?e.getGlobalAutoFilterFn():(t=(r=e.options.filterFns)==null?void 0:r[n])!=null?t:At[n]},setColumnFilters:t=>{const r=e.getAllLeafColumns(),n=o=>{var i;return(i=dr(t,o))==null?void 0:i.filter(l=>{const a=r.find(s=>s.id===l.id);if(a){const s=a.getFilterFn();if(i0(s,l.value,a))return!1}return!0})};e.options.onColumnFiltersChange==null||e.options.onColumnFiltersChange(n)},setGlobalFilter:t=>{e.options.onGlobalFilterChange==null||e.options.onGlobalFilterChange(t)},resetGlobalFilter:t=>{e.setGlobalFilter(t?void 0:e.initialState.globalFilter)},resetColumnFilters:t=>{var r,n;e.setColumnFilters(t?[]:(r=(n=e.initialState)==null?void 0:n.columnFilters)!=null?r:[])},getPreFilteredRowModel:()=>e.getCoreRowModel(),getFilteredRowModel:()=>(!e._getFilteredRowModel&&e.options.getFilteredRowModel&&(e._getFilteredRowModel=e.options.getFilteredRowModel(e)),e.options.manualFiltering||!e._getFilteredRowModel?e.getPreFilteredRowModel():e._getFilteredRowModel()),_getGlobalFacetedRowModel:e.options.getFacetedRowModel&&e.options.getFacetedRowModel(e,"__global__"),getGlobalFacetedRowModel:()=>e.options.manualFiltering||!e._getGlobalFacetedRowModel?e.getPreFilteredRowModel():e._getGlobalFacetedRowModel(),_getGlobalFacetedUniqueValues:e.options.getFacetedUniqueValues&&e.options.getFacetedUniqueValues(e,"__global__"),getGlobalFacetedUniqueValues:()=>e._getGlobalFacetedUniqueValues?e._getGlobalFacetedUniqueValues():new Map,_getGlobalFacetedMinMaxValues:e.options.getFacetedMinMaxValues&&e.options.getFacetedMinMaxValues(e,"__global__"),getGlobalFacetedMinMaxValues:()=>{if(!!e._getGlobalFacetedMinMaxValues)return e._getGlobalFacetedMinMaxValues()}})};function i0(e,t,r){return(e&&e.autoRemove?e.autoRemove(t,r):!1)||typeof t>"u"||typeof t=="string"&&!t}const SD=(e,t,r)=>r.reduce((n,o)=>{const i=o.getValue(e);return n+(typeof i=="number"?i:0)},0),bD=(e,t,r)=>{let n;return r.forEach(o=>{const i=o.getValue(e);i!=null&&(n>i||n===void 0&&i>=i)&&(n=i)}),n},xD=(e,t,r)=>{let n;return r.forEach(o=>{const i=o.getValue(e);i!=null&&(n=i)&&(n=i)}),n},PD=(e,t,r)=>{let n,o;return r.forEach(i=>{const l=i.getValue(e);l!=null&&(n===void 0?l>=l&&(n=o=l):(n>l&&(n=l),o{let r=0,n=0;if(t.forEach(o=>{let i=o.getValue(e);i!=null&&(i=+i)>=i&&(++r,n+=i)}),r)return n/r},OD=(e,t)=>{if(!t.length)return;let r=0,n=0;return t.forEach(o=>{let i=o.getValue(e);typeof i=="number"&&(r=Math.min(r,i),n=Math.max(n,i))}),(r+n)/2},CD=(e,t)=>Array.from(new Set(t.map(r=>r.getValue(e))).values()),ED=(e,t)=>new Set(t.map(r=>r.getValue(e))).size,kD=(e,t)=>t.length,vc={sum:SD,min:bD,max:xD,extent:PD,mean:$D,median:OD,unique:CD,uniqueCount:ED,count:kD},RD={getDefaultColumnDef:()=>({aggregatedCell:e=>{var t,r;return(t=(r=e.getValue())==null||r.toString==null?void 0:r.toString())!=null?t:null},aggregationFn:"auto"}),getInitialState:e=>({grouping:[],...e}),getDefaultOptions:e=>({onGroupingChange:vt("grouping",e),groupedColumnMode:"reorder"}),createColumn:(e,t)=>({toggleGrouping:()=>{t.setGrouping(r=>r!=null&&r.includes(e.id)?r.filter(n=>n!==e.id):[...r??[],e.id])},getCanGroup:()=>{var r,n,o,i;return(r=(n=(o=(i=e.columnDef.enableGrouping)!=null?i:!0)!=null?o:t.options.enableGrouping)!=null?n:!0)!=null?r:!!e.accessorFn},getIsGrouped:()=>{var r;return(r=t.getState().grouping)==null?void 0:r.includes(e.id)},getGroupedIndex:()=>{var r;return(r=t.getState().grouping)==null?void 0:r.indexOf(e.id)},getToggleGroupingHandler:()=>{const r=e.getCanGroup();return()=>{!r||e.toggleGrouping()}},getAutoAggregationFn:()=>{const r=t.getCoreRowModel().flatRows[0],n=r?.getValue(e.id);if(typeof n=="number")return vc.sum;if(Object.prototype.toString.call(n)==="[object Date]")return vc.extent},getAggregationFn:()=>{var r,n;if(!e)throw new Error;return Cs(e.columnDef.aggregationFn)?e.columnDef.aggregationFn:e.columnDef.aggregationFn==="auto"?e.getAutoAggregationFn():(r=(n=t.options.aggregationFns)==null?void 0:n[e.columnDef.aggregationFn])!=null?r:vc[e.columnDef.aggregationFn]}}),createTable:e=>({setGrouping:t=>e.options.onGroupingChange==null?void 0:e.options.onGroupingChange(t),resetGrouping:t=>{var r,n;e.setGrouping(t?[]:(r=(n=e.initialState)==null?void 0:n.grouping)!=null?r:[])},getPreGroupedRowModel:()=>e.getFilteredRowModel(),getGroupedRowModel:()=>(!e._getGroupedRowModel&&e.options.getGroupedRowModel&&(e._getGroupedRowModel=e.options.getGroupedRowModel(e)),e.options.manualGrouping||!e._getGroupedRowModel?e.getPreGroupedRowModel():e._getGroupedRowModel())}),createRow:e=>({getIsGrouped:()=>!!e.groupingColumnId,_groupingValuesCache:{}}),createCell:(e,t,r,n)=>({getIsGrouped:()=>t.getIsGrouped()&&t.id===r.groupingColumnId,getIsPlaceholder:()=>!e.getIsGrouped()&&t.getIsGrouped(),getIsAggregated:()=>{var o;return!e.getIsGrouped()&&!e.getIsPlaceholder()&&!!((o=r.subRows)!=null&&o.length)}})};function ID(e,t,r){if(!(t!=null&&t.length)||!r)return e;const n=e.filter(i=>!t.includes(i.id));return r==="remove"?n:[...t.map(i=>e.find(l=>l.id===i)).filter(Boolean),...n]}const ND={getInitialState:e=>({columnOrder:[],...e}),getDefaultOptions:e=>({onColumnOrderChange:vt("columnOrder",e)}),createTable:e=>({setColumnOrder:t=>e.options.onColumnOrderChange==null?void 0:e.options.onColumnOrderChange(t),resetColumnOrder:t=>{var r;e.setColumnOrder(t?[]:(r=e.initialState.columnOrder)!=null?r:[])},_getOrderColumnsFn:X(()=>[e.getState().columnOrder,e.getState().grouping,e.options.groupedColumnMode],(t,r,n)=>o=>{let i=[];if(!(t!=null&&t.length))i=o;else{const l=[...t],a=[...o];for(;a.length&&l.length;){const s=l.shift(),u=a.findIndex(c=>c.id===s);u>-1&&i.push(a.splice(u,1)[0])}i=[...i,...a]}return ID(i,r,n)},{key:!1})})},$f=0,Of=10,hc=()=>({pageIndex:$f,pageSize:Of}),zD={getInitialState:e=>({...e,pagination:{...hc(),...e?.pagination}}),getDefaultOptions:e=>({onPaginationChange:vt("pagination",e)}),createTable:e=>{let t=!1,r=!1;return{_autoResetPageIndex:()=>{var n,o;if(!t){e._queue(()=>{t=!0});return}if((n=(o=e.options.autoResetAll)!=null?o:e.options.autoResetPageIndex)!=null?n:!e.options.manualPagination){if(r)return;r=!0,e._queue(()=>{e.resetPageIndex(),r=!1})}},setPagination:n=>{const o=i=>dr(n,i);return e.options.onPaginationChange==null?void 0:e.options.onPaginationChange(o)},resetPagination:n=>{var o;e.setPagination(n?hc():(o=e.initialState.pagination)!=null?o:hc())},setPageIndex:n=>{e.setPagination(o=>{let i=dr(n,o.pageIndex);const l=typeof e.options.pageCount>"u"||e.options.pageCount===-1?Number.MAX_SAFE_INTEGER:e.options.pageCount-1;return i=Math.min(Math.max(0,i),l),{...o,pageIndex:i}})},resetPageIndex:n=>{var o,i,l;e.setPageIndex(n?$f:(o=(i=e.initialState)==null||(l=i.pagination)==null?void 0:l.pageIndex)!=null?o:$f)},resetPageSize:n=>{var o,i,l;e.setPageSize(n?Of:(o=(i=e.initialState)==null||(l=i.pagination)==null?void 0:l.pageSize)!=null?o:Of)},setPageSize:n=>{e.setPagination(o=>{const i=Math.max(1,dr(n,o.pageSize)),l=o.pageSize*o.pageIndex,a=Math.floor(l/i);return{...o,pageIndex:a,pageSize:i}})},setPageCount:n=>e.setPagination(o=>{var i;let l=dr(n,(i=e.options.pageCount)!=null?i:-1);return typeof l=="number"&&(l=Math.max(-1,l)),{...o,pageCount:l}}),getPageOptions:X(()=>[e.getPageCount()],n=>{let o=[];return n&&n>0&&(o=[...new Array(n)].fill(null).map((i,l)=>l)),o},{key:!1,debug:()=>{var n;return(n=e.options.debugAll)!=null?n:e.options.debugTable}}),getCanPreviousPage:()=>e.getState().pagination.pageIndex>0,getCanNextPage:()=>{const{pageIndex:n}=e.getState().pagination,o=e.getPageCount();return o===-1?!0:o===0?!1:ne.setPageIndex(n=>n-1),nextPage:()=>e.setPageIndex(n=>n+1),getPrePaginationRowModel:()=>e.getExpandedRowModel(),getPaginationRowModel:()=>(!e._getPaginationRowModel&&e.options.getPaginationRowModel&&(e._getPaginationRowModel=e.options.getPaginationRowModel(e)),e.options.manualPagination||!e._getPaginationRowModel?e.getPrePaginationRowModel():e._getPaginationRowModel()),getPageCount:()=>{var n;return(n=e.options.pageCount)!=null?n:Math.ceil(e.getPrePaginationRowModel().rows.length/e.getState().pagination.pageSize)}}}},yc=()=>({left:[],right:[]}),DD={getInitialState:e=>({columnPinning:yc(),...e}),getDefaultOptions:e=>({onColumnPinningChange:vt("columnPinning",e)}),createColumn:(e,t)=>({pin:r=>{const n=e.getLeafColumns().map(o=>o.id).filter(Boolean);t.setColumnPinning(o=>{var i,l;if(r==="right"){var a,s;return{left:((a=o?.left)!=null?a:[]).filter(f=>!(n!=null&&n.includes(f))),right:[...((s=o?.right)!=null?s:[]).filter(f=>!(n!=null&&n.includes(f))),...n]}}if(r==="left"){var u,c;return{left:[...((u=o?.left)!=null?u:[]).filter(f=>!(n!=null&&n.includes(f))),...n],right:((c=o?.right)!=null?c:[]).filter(f=>!(n!=null&&n.includes(f)))}}return{left:((i=o?.left)!=null?i:[]).filter(f=>!(n!=null&&n.includes(f))),right:((l=o?.right)!=null?l:[]).filter(f=>!(n!=null&&n.includes(f)))}})},getCanPin:()=>e.getLeafColumns().some(n=>{var o,i;return((o=n.columnDef.enablePinning)!=null?o:!0)&&((i=t.options.enablePinning)!=null?i:!0)}),getIsPinned:()=>{const r=e.getLeafColumns().map(a=>a.id),{left:n,right:o}=t.getState().columnPinning,i=r.some(a=>n?.includes(a)),l=r.some(a=>o?.includes(a));return i?"left":l?"right":!1},getPinnedIndex:()=>{var r,n,o;const i=e.getIsPinned();return i?(r=(n=t.getState().columnPinning)==null||(o=n[i])==null?void 0:o.indexOf(e.id))!=null?r:-1:0}}),createRow:(e,t)=>({getCenterVisibleCells:X(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left,t.getState().columnPinning.right],(r,n,o)=>{const i=[...n??[],...o??[]];return r.filter(l=>!i.includes(l.column.id))},{key:"row.getCenterVisibleCells",debug:()=>{var r;return(r=t.options.debugAll)!=null?r:t.options.debugRows}}),getLeftVisibleCells:X(()=>[e._getAllVisibleCells(),t.getState().columnPinning.left,,],(r,n)=>(n??[]).map(i=>r.find(l=>l.column.id===i)).filter(Boolean).map(i=>({...i,position:"left"})),{key:"row.getLeftVisibleCells",debug:()=>{var r;return(r=t.options.debugAll)!=null?r:t.options.debugRows}}),getRightVisibleCells:X(()=>[e._getAllVisibleCells(),t.getState().columnPinning.right],(r,n)=>(n??[]).map(i=>r.find(l=>l.column.id===i)).filter(Boolean).map(i=>({...i,position:"left"})),{key:"row.getRightVisibleCells",debug:()=>{var r;return(r=t.options.debugAll)!=null?r:t.options.debugRows}})}),createTable:e=>({setColumnPinning:t=>e.options.onColumnPinningChange==null?void 0:e.options.onColumnPinningChange(t),resetColumnPinning:t=>{var r,n;return e.setColumnPinning(t?yc():(r=(n=e.initialState)==null?void 0:n.columnPinning)!=null?r:yc())},getIsSomeColumnsPinned:t=>{var r;const n=e.getState().columnPinning;if(!t){var o,i;return Boolean(((o=n.left)==null?void 0:o.length)||((i=n.right)==null?void 0:i.length))}return Boolean((r=n[t])==null?void 0:r.length)},getLeftLeafColumns:X(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left],(t,r)=>(r??[]).map(n=>t.find(o=>o.id===n)).filter(Boolean),{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugColumns}}),getRightLeafColumns:X(()=>[e.getAllLeafColumns(),e.getState().columnPinning.right],(t,r)=>(r??[]).map(n=>t.find(o=>o.id===n)).filter(Boolean),{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugColumns}}),getCenterLeafColumns:X(()=>[e.getAllLeafColumns(),e.getState().columnPinning.left,e.getState().columnPinning.right],(t,r,n)=>{const o=[...r??[],...n??[]];return t.filter(i=>!o.includes(i.id))},{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugColumns}})})},TD={getInitialState:e=>({rowSelection:{},...e}),getDefaultOptions:e=>({onRowSelectionChange:vt("rowSelection",e),enableRowSelection:!0,enableMultiRowSelection:!0,enableSubRowSelection:!0}),createTable:e=>({setRowSelection:t=>e.options.onRowSelectionChange==null?void 0:e.options.onRowSelectionChange(t),resetRowSelection:t=>{var r;return e.setRowSelection(t?{}:(r=e.initialState.rowSelection)!=null?r:{})},toggleAllRowsSelected:t=>{e.setRowSelection(r=>{t=typeof t<"u"?t:!e.getIsAllRowsSelected();const n={...r},o=e.getPreGroupedRowModel().flatRows;return t?o.forEach(i=>{!i.getCanSelect()||(n[i.id]=!0)}):o.forEach(i=>{delete n[i.id]}),n})},toggleAllPageRowsSelected:t=>e.setRowSelection(r=>{const n=typeof t<"u"?t:!e.getIsAllPageRowsSelected(),o={...r};return e.getRowModel().rows.forEach(i=>{Cf(o,i.id,n,e)}),o}),getPreSelectedRowModel:()=>e.getCoreRowModel(),getSelectedRowModel:X(()=>[e.getState().rowSelection,e.getCoreRowModel()],(t,r)=>Object.keys(t).length?wc(e,r):{rows:[],flatRows:[],rowsById:{}},{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugTable}}),getFilteredSelectedRowModel:X(()=>[e.getState().rowSelection,e.getFilteredRowModel()],(t,r)=>Object.keys(t).length?wc(e,r):{rows:[],flatRows:[],rowsById:{}},{key:"getFilteredSelectedRowModel",debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugTable}}),getGroupedSelectedRowModel:X(()=>[e.getState().rowSelection,e.getSortedRowModel()],(t,r)=>Object.keys(t).length?wc(e,r):{rows:[],flatRows:[],rowsById:{}},{key:"getGroupedSelectedRowModel",debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugTable}}),getIsAllRowsSelected:()=>{const t=e.getFilteredRowModel().flatRows,{rowSelection:r}=e.getState();let n=Boolean(t.length&&Object.keys(r).length);return n&&t.some(o=>o.getCanSelect()&&!r[o.id])&&(n=!1),n},getIsAllPageRowsSelected:()=>{const t=e.getPaginationRowModel().flatRows,{rowSelection:r}=e.getState();let n=!!t.length;return n&&t.some(o=>!r[o.id])&&(n=!1),n},getIsSomeRowsSelected:()=>{var t;const r=Object.keys((t=e.getState().rowSelection)!=null?t:{}).length;return r>0&&r{const t=e.getPaginationRowModel().flatRows;return e.getIsAllPageRowsSelected()?!1:t.some(r=>r.getIsSelected()||r.getIsSomeSelected())},getToggleAllRowsSelectedHandler:()=>t=>{e.toggleAllRowsSelected(t.target.checked)},getToggleAllPageRowsSelectedHandler:()=>t=>{e.toggleAllPageRowsSelected(t.target.checked)}}),createRow:(e,t)=>({toggleSelected:r=>{const n=e.getIsSelected();t.setRowSelection(o=>{if(r=typeof r<"u"?r:!n,n===r)return o;const i={...o};return Cf(i,e.id,r,t),i})},getIsSelected:()=>{const{rowSelection:r}=t.getState();return up(e,r)},getIsSomeSelected:()=>{const{rowSelection:r}=t.getState();return l0(e,r)==="some"},getIsAllSubRowsSelected:()=>{const{rowSelection:r}=t.getState();return l0(e,r)==="all"},getCanSelect:()=>{var r;return typeof t.options.enableRowSelection=="function"?t.options.enableRowSelection(e):(r=t.options.enableRowSelection)!=null?r:!0},getCanSelectSubRows:()=>{var r;return typeof t.options.enableSubRowSelection=="function"?t.options.enableSubRowSelection(e):(r=t.options.enableSubRowSelection)!=null?r:!0},getCanMultiSelect:()=>{var r;return typeof t.options.enableMultiRowSelection=="function"?t.options.enableMultiRowSelection(e):(r=t.options.enableMultiRowSelection)!=null?r:!0},getToggleSelectedHandler:()=>{const r=e.getCanSelect();return n=>{var o;!r||e.toggleSelected((o=n.target)==null?void 0:o.checked)}}})},Cf=(e,t,r,n)=>{var o;const i=n.getRow(t);r?(i.getCanMultiSelect()||Object.keys(e).forEach(l=>delete e[l]),i.getCanSelect()&&(e[t]=!0)):delete e[t],(o=i.subRows)!=null&&o.length&&i.getCanSelectSubRows()&&i.subRows.forEach(l=>Cf(e,l.id,r,n))};function wc(e,t){const r=e.getState().rowSelection,n=[],o={},i=function(l,a){return l.map(s=>{var u;const c=up(s,r);if(c&&(n.push(s),o[s.id]=s),(u=s.subRows)!=null&&u.length&&(s={...s,subRows:i(s.subRows)}),c)return s}).filter(Boolean)};return{rows:i(t.rows),flatRows:n,rowsById:o}}function up(e,t){var r;return(r=t[e.id])!=null?r:!1}function l0(e,t,r){if(e.subRows&&e.subRows.length){let n=!0,o=!1;return e.subRows.forEach(i=>{o&&!n||(up(i,t)?o=!0:n=!1)}),n?"all":o?"some":!1}return!1}const Ef=/([0-9]+)/gm,MD=(e,t,r)=>ex(Ir(e.getValue(r)).toLowerCase(),Ir(t.getValue(r)).toLowerCase()),jD=(e,t,r)=>ex(Ir(e.getValue(r)),Ir(t.getValue(r))),LD=(e,t,r)=>cp(Ir(e.getValue(r)).toLowerCase(),Ir(t.getValue(r)).toLowerCase()),FD=(e,t,r)=>cp(Ir(e.getValue(r)),Ir(t.getValue(r))),AD=(e,t,r)=>{const n=e.getValue(r),o=t.getValue(r);return n>o?1:ncp(e.getValue(r),t.getValue(r));function cp(e,t){return e===t?0:e>t?1:-1}function Ir(e){return typeof e=="number"?isNaN(e)||e===1/0||e===-1/0?"":String(e):typeof e=="string"?e:""}function ex(e,t){const r=e.split(Ef).filter(Boolean),n=t.split(Ef).filter(Boolean);for(;r.length&&n.length;){const o=r.shift(),i=n.shift(),l=parseInt(o,10),a=parseInt(i,10),s=[l,a].sort();if(isNaN(s[0])){if(o>i)return 1;if(i>o)return-1;continue}if(isNaN(s[1]))return isNaN(l)?-1:1;if(l>a)return 1;if(a>l)return-1}return r.length-n.length}const jo={alphanumeric:MD,alphanumericCaseSensitive:jD,text:LD,textCaseSensitive:FD,datetime:AD,basic:VD},HD={getInitialState:e=>({sorting:[],...e}),getDefaultColumnDef:()=>({sortingFn:"auto"}),getDefaultOptions:e=>({onSortingChange:vt("sorting",e),isMultiSortEvent:t=>t.shiftKey}),createColumn:(e,t)=>({getAutoSortingFn:()=>{const r=t.getFilteredRowModel().flatRows.slice(10);let n=!1;for(const o of r){const i=o?.getValue(e.id);if(Object.prototype.toString.call(i)==="[object Date]")return jo.datetime;if(typeof i=="string"&&(n=!0,i.split(Ef).length>1))return jo.alphanumeric}return n?jo.text:jo.basic},getAutoSortDir:()=>{const r=t.getFilteredRowModel().flatRows[0];return typeof r?.getValue(e.id)=="string"?"asc":"desc"},getSortingFn:()=>{var r,n;if(!e)throw new Error;return Cs(e.columnDef.sortingFn)?e.columnDef.sortingFn:e.columnDef.sortingFn==="auto"?e.getAutoSortingFn():(r=(n=t.options.sortingFns)==null?void 0:n[e.columnDef.sortingFn])!=null?r:jo[e.columnDef.sortingFn]},toggleSorting:(r,n)=>{const o=e.getNextSortingOrder(),i=typeof r<"u"&&r!==null;t.setSorting(l=>{const a=l?.find(p=>p.id===e.id),s=l?.findIndex(p=>p.id===e.id);let u=[],c,f=i?r:o==="desc";if(l!=null&&l.length&&e.getCanMultiSort()&&n?a?c="toggle":c="add":l!=null&&l.length&&s!==l.length-1?c="replace":a?c="toggle":c="replace",c==="toggle"&&(i||o||(c="remove")),c==="add"){var d;u=[...l,{id:e.id,desc:f}],u.splice(0,u.length-((d=t.options.maxMultiSortColCount)!=null?d:Number.MAX_SAFE_INTEGER))}else c==="toggle"?u=l.map(p=>p.id===e.id?{...p,desc:f}:p):c==="remove"?u=l.filter(p=>p.id!==e.id):u=[{id:e.id,desc:f}];return u})},getFirstSortDir:()=>{var r,n;return((r=(n=e.columnDef.sortDescFirst)!=null?n:t.options.sortDescFirst)!=null?r:e.getAutoSortDir()==="desc")?"desc":"asc"},getNextSortingOrder:r=>{var n,o;const i=e.getFirstSortDir(),l=e.getIsSorted();return l?l!==i&&((n=t.options.enableSortingRemoval)!=null?n:!0)&&(r&&(o=t.options.enableMultiRemove)!=null?o:!0)?!1:l==="desc"?"asc":"desc":i},getCanSort:()=>{var r,n;return((r=e.columnDef.enableSorting)!=null?r:!0)&&((n=t.options.enableSorting)!=null?n:!0)&&!!e.accessorFn},getCanMultiSort:()=>{var r,n;return(r=(n=e.columnDef.enableMultiSort)!=null?n:t.options.enableMultiSort)!=null?r:!!e.accessorFn},getIsSorted:()=>{var r;const n=(r=t.getState().sorting)==null?void 0:r.find(o=>o.id===e.id);return n?n.desc?"desc":"asc":!1},getSortIndex:()=>{var r,n;return(r=(n=t.getState().sorting)==null?void 0:n.findIndex(o=>o.id===e.id))!=null?r:-1},clearSorting:()=>{t.setSorting(r=>r!=null&&r.length?r.filter(n=>n.id!==e.id):[])},getToggleSortingHandler:()=>{const r=e.getCanSort();return n=>{!r||(n.persist==null||n.persist(),e.toggleSorting==null||e.toggleSorting(void 0,e.getCanMultiSort()?t.options.isMultiSortEvent==null?void 0:t.options.isMultiSortEvent(n):!1))}}}),createTable:e=>({setSorting:t=>e.options.onSortingChange==null?void 0:e.options.onSortingChange(t),resetSorting:t=>{var r,n;e.setSorting(t?[]:(r=(n=e.initialState)==null?void 0:n.sorting)!=null?r:[])},getPreSortedRowModel:()=>e.getGroupedRowModel(),getSortedRowModel:()=>(!e._getSortedRowModel&&e.options.getSortedRowModel&&(e._getSortedRowModel=e.options.getSortedRowModel(e)),e.options.manualSorting||!e._getSortedRowModel?e.getPreSortedRowModel():e._getSortedRowModel())})},BD={getInitialState:e=>({columnVisibility:{},...e}),getDefaultOptions:e=>({onColumnVisibilityChange:vt("columnVisibility",e)}),createColumn:(e,t)=>({toggleVisibility:r=>{e.getCanHide()&&t.setColumnVisibility(n=>({...n,[e.id]:r??!e.getIsVisible()}))},getIsVisible:()=>{var r,n;return(r=(n=t.getState().columnVisibility)==null?void 0:n[e.id])!=null?r:!0},getCanHide:()=>{var r,n;return((r=e.columnDef.enableHiding)!=null?r:!0)&&((n=t.options.enableHiding)!=null?n:!0)},getToggleVisibilityHandler:()=>r=>{e.toggleVisibility==null||e.toggleVisibility(r.target.checked)}}),createRow:(e,t)=>({_getAllVisibleCells:X(()=>[e.getAllCells(),t.getState().columnVisibility],r=>r.filter(n=>n.column.getIsVisible()),{key:"row._getAllVisibleCells",debug:()=>{var r;return(r=t.options.debugAll)!=null?r:t.options.debugRows}}),getVisibleCells:X(()=>[e.getLeftVisibleCells(),e.getCenterVisibleCells(),e.getRightVisibleCells()],(r,n,o)=>[...r,...n,...o],{key:!1,debug:()=>{var r;return(r=t.options.debugAll)!=null?r:t.options.debugRows}})}),createTable:e=>{const t=(r,n)=>X(()=>[n(),n().filter(o=>o.getIsVisible()).map(o=>o.id).join("_")],o=>o.filter(i=>i.getIsVisible==null?void 0:i.getIsVisible()),{key:r,debug:()=>{var o;return(o=e.options.debugAll)!=null?o:e.options.debugColumns}});return{getVisibleFlatColumns:t("getVisibleFlatColumns",()=>e.getAllFlatColumns()),getVisibleLeafColumns:t("getVisibleLeafColumns",()=>e.getAllLeafColumns()),getLeftVisibleLeafColumns:t("getLeftVisibleLeafColumns",()=>e.getLeftLeafColumns()),getRightVisibleLeafColumns:t("getRightVisibleLeafColumns",()=>e.getRightLeafColumns()),getCenterVisibleLeafColumns:t("getCenterVisibleLeafColumns",()=>e.getCenterLeafColumns()),setColumnVisibility:r=>e.options.onColumnVisibilityChange==null?void 0:e.options.onColumnVisibilityChange(r),resetColumnVisibility:r=>{var n;e.setColumnVisibility(r?{}:(n=e.initialState.columnVisibility)!=null?n:{})},toggleAllColumnsVisible:r=>{var n;r=(n=r)!=null?n:!e.getIsAllColumnsVisible(),e.setColumnVisibility(e.getAllLeafColumns().reduce((o,i)=>({...o,[i.id]:r||!(i.getCanHide!=null&&i.getCanHide())}),{}))},getIsAllColumnsVisible:()=>!e.getAllLeafColumns().some(r=>!(r.getIsVisible!=null&&r.getIsVisible())),getIsSomeColumnsVisible:()=>e.getAllLeafColumns().some(r=>r.getIsVisible==null?void 0:r.getIsVisible()),getToggleAllColumnsVisibilityHandler:()=>r=>{var n;e.toggleAllColumnsVisible((n=r.target)==null?void 0:n.checked)}}}},a0=[vD,BD,ND,DD,_D,HD,RD,wD,zD,TD,hD];function WD(e){var t;(e.debugAll||e.debugTable)&&console.info("Creating Table Instance...");let r={_features:a0};const n=r._features.reduce((c,f)=>Object.assign(c,f.getDefaultOptions==null?void 0:f.getDefaultOptions(r)),{}),o=c=>r.options.mergeOptions?r.options.mergeOptions(n,c):{...n,...c};let l={...{},...(t=e.initialState)!=null?t:{}};r._features.forEach(c=>{var f;l=(f=c.getInitialState==null?void 0:c.getInitialState(l))!=null?f:l});const a=[];let s=!1;const u={_features:a0,options:{...n,...e},initialState:l,_queue:c=>{a.push(c),s||(s=!0,Promise.resolve().then(()=>{for(;a.length;)a.shift()();s=!1}).catch(f=>setTimeout(()=>{throw f})))},reset:()=>{r.setState(r.initialState)},setOptions:c=>{const f=dr(c,r.options);r.options=o(f)},getState:()=>r.options.state,setState:c=>{r.options.onStateChange==null||r.options.onStateChange(c)},_getRowId:(c,f,d)=>{var p;return(p=r.options.getRowId==null?void 0:r.options.getRowId(c,f,d))!=null?p:""+(d?[d.id,f].join("."):f)},getCoreRowModel:()=>(r._getCoreRowModel||(r._getCoreRowModel=r.options.getCoreRowModel(r)),r._getCoreRowModel()),getRowModel:()=>r.getPaginationRowModel(),getRow:c=>{const f=r.getRowModel().rowsById[c];if(!f)throw new Error;return f},_getDefaultColumnDef:X(()=>[r.options.defaultColumn],c=>{var f;return c=(f=c)!=null?f:{},{header:d=>{const p=d.header.column.columnDef;return p.accessorKey?p.accessorKey:p.accessorFn?p.id:null},cell:d=>{var p,y;return(p=(y=d.renderValue())==null||y.toString==null?void 0:y.toString())!=null?p:null},...r._features.reduce((d,p)=>Object.assign(d,p.getDefaultColumnDef==null?void 0:p.getDefaultColumnDef()),{}),...c}},{debug:()=>{var c;return(c=r.options.debugAll)!=null?c:r.options.debugColumns},key:!1}),_getColumnDefs:()=>r.options.columns,getAllColumns:X(()=>[r._getColumnDefs()],c=>{const f=function(d,p,y){return y===void 0&&(y=0),d.map(w=>{const v=mD(r,w,y,p),m=w;return v.columns=m.columns?f(m.columns,v,y+1):[],v})};return f(c)},{key:!1,debug:()=>{var c;return(c=r.options.debugAll)!=null?c:r.options.debugColumns}}),getAllFlatColumns:X(()=>[r.getAllColumns()],c=>c.flatMap(f=>f.getFlatColumns()),{key:!1,debug:()=>{var c;return(c=r.options.debugAll)!=null?c:r.options.debugColumns}}),_getAllFlatColumnsById:X(()=>[r.getAllFlatColumns()],c=>c.reduce((f,d)=>(f[d.id]=d,f),{}),{key:!1,debug:()=>{var c;return(c=r.options.debugAll)!=null?c:r.options.debugColumns}}),getAllLeafColumns:X(()=>[r.getAllColumns(),r._getOrderColumnsFn()],(c,f)=>{let d=c.flatMap(p=>p.getLeafColumns());return f(d)},{key:!1,debug:()=>{var c;return(c=r.options.debugAll)!=null?c:r.options.debugColumns}}),getColumn:c=>{const f=r._getAllFlatColumnsById()[c];if(!f)throw new Error;return f}};return Object.assign(r,u),r._features.forEach(c=>Object.assign(r,c.createTable==null?void 0:c.createTable(r))),r}function UD(e,t,r,n){const o=()=>{var l;return(l=i.getValue())!=null?l:e.options.renderFallbackValue},i={id:t.id+"_"+r.id,row:t,column:r,getValue:()=>t.getValue(n),renderValue:o,getContext:()=>({table:e,column:r,row:t,cell:i,getValue:i.getValue,renderValue:i.renderValue})};return e._features.forEach(l=>{Object.assign(i,l.createCell==null?void 0:l.createCell(i,r,t,e))},{}),i}const fp=(e,t,r,n,o,i)=>{let l={id:t,index:n,original:r,depth:o,_valuesCache:{},getValue:a=>{if(l._valuesCache.hasOwnProperty(a))return l._valuesCache[a];const s=e.getColumn(a);if(!!s.accessorFn)return l._valuesCache[a]=s.accessorFn(l.original,n),l._valuesCache[a]},renderValue:a=>{var s;return(s=l.getValue(a))!=null?s:e.options.renderFallbackValue},subRows:i??[],getLeafRows:()=>gD(l.subRows,a=>a.subRows),getAllCells:X(()=>[e.getAllLeafColumns()],a=>a.map(s=>UD(e,l,s,s.id)),{key:!1,debug:()=>{var a;return(a=e.options.debugAll)!=null?a:e.options.debugRows}}),_getAllCellsByColumnId:X(()=>[l.getAllCells()],a=>a.reduce((s,u)=>(s[u.column.id]=u,s),{}),{key:"row.getAllCellsByColumnId",debug:()=>{var a;return(a=e.options.debugAll)!=null?a:e.options.debugRows}})};for(let a=0;aX(()=>[e.options.data],t=>{const r={rows:[],flatRows:[],rowsById:{}},n=function(o,i,l){i===void 0&&(i=0);const a=[];for(let u=0;u{var t;return(t=e.options.debugAll)!=null?t:e.options.debugTable},onChange:()=>{e._autoResetPageIndex()}})}function YD(e,t,r){return r.options.filterFromLeafRows?XD(e,t,r):qD(e,t,r)}function XD(e,t,r){const n=[],o={},i=function(l,a){const s=[];for(let c=0;cX(()=>[e.getPreFilteredRowModel(),e.getState().columnFilters,e.getState().globalFilter],(t,r,n)=>{if(!t.rows.length||!(r!=null&&r.length)&&!n){for(let d=0;d{var p;const w=e.getColumn(d.id).getFilterFn();!w||o.push({id:d.id,filterFn:w,resolvedValue:(p=w.resolveFilterValue==null?void 0:w.resolveFilterValue(d.value))!=null?p:d.value})});const l=r.map(d=>d.id),a=e.getGlobalFilterFn(),s=e.getAllLeafColumns().filter(d=>d.getCanGlobalFilter());n&&a&&s.length&&(l.push("__global__"),s.forEach(d=>{var p;i.push({id:d.id,filterFn:a,resolvedValue:(p=a.resolveFilterValue==null?void 0:a.resolveFilterValue(n))!=null?p:n})}));let u,c;for(let d=0;d{p.columnFiltersMeta[w]=v})}if(i.length){for(let y=0;y{p.columnFiltersMeta[w]=v})){p.columnFilters.__global__=!0;break}}p.columnFilters.__global__!==!0&&(p.columnFilters.__global__=!1)}}const f=d=>{for(let p=0;p{var t;return(t=e.options.debugAll)!=null?t:e.options.debugTable},onChange:()=>{e._autoResetPageIndex()}})}function QD(){return e=>X(()=>[e.getState().sorting,e.getPreSortedRowModel()],(t,r)=>{if(!r.rows.length||!(t!=null&&t.length))return r;const n=e.getState().sorting,o=[],i=n.filter(s=>e.getColumn(s.id).getCanSort()),l={};i.forEach(s=>{const u=e.getColumn(s.id);l[s.id]={sortUndefined:u.columnDef.sortUndefined,invertSorting:u.columnDef.invertSorting,sortingFn:u.getSortingFn()}});const a=s=>{const u=s.slice();return u.sort((c,f)=>{for(let p=0;p"u",O=typeof _>"u";if(b||O)return b&&O?0:b?w.sortUndefined:-w.sortUndefined}let m=w.sortingFn(c,f,y.id);if(m!==0)return v&&(m*=-1),w.invertSorting&&(m*=-1),m}return c.index-f.index}),u.forEach(c=>{o.push(c),!(!c.subRows||c.subRows.length<=1)&&(c.subRows=a(c.subRows))}),u};return{rows:a(r.rows),flatRows:o,rowsById:r.rowsById}},{key:!1,debug:()=>{var t;return(t=e.options.debugAll)!=null?t:e.options.debugTable},onChange:()=>{e._autoResetPageIndex()}})}function ZD(e){const t=[],r=n=>{var o;t.push(n),(o=n.subRows)!=null&&o.length&&n.getIsExpanded()&&n.subRows.forEach(r)};return e.rows.forEach(r),{rows:t,flatRows:e.flatRows,rowsById:e.rowsById}}function JD(e){return t=>X(()=>[t.getState().pagination,t.getPrePaginationRowModel(),t.options.paginateExpandedRows?void 0:t.getState().expanded],(r,n)=>{if(!n.rows.length)return n;const{pageSize:o,pageIndex:i}=r;let{rows:l,flatRows:a,rowsById:s}=n;const u=o*i,c=u+o;l=l.slice(u,c);let f;t.options.paginateExpandedRows?f={rows:l,flatRows:a,rowsById:s}:f=ZD({rows:l,flatRows:a,rowsById:s}),f.flatRows=[];const d=p=>{f.flatRows.push(p),p.subRows.length&&p.subRows.forEach(d)};return f.rows.forEach(d),f},{key:!1,debug:()=>{var r;return(r=t.options.debugAll)!=null?r:t.options.debugTable}})}function s0(e,t){return e?eT(e)?g.exports.createElement(e,t):e:null}function eT(e){return tT(e)||typeof e=="function"||rT(e)}function tT(e){return typeof e=="function"&&(()=>{const t=Object.getPrototypeOf(e);return t.prototype&&t.prototype.isReactComponent})()}function rT(e){return typeof e=="object"&&typeof e.$$typeof=="symbol"&&["react.memo","react.forward_ref"].includes(e.$$typeof.description)}function nT(e){const t={state:{},onStateChange:()=>{},renderFallbackValue:null,...e},[r]=g.exports.useState(()=>({current:WD(t)})),[n,o]=g.exports.useState(()=>r.current.initialState);return r.current.setOptions(i=>({...i,...e,state:{...n,...e.state},onStateChange:l=>{o(l),e.onStateChange==null||e.onStateChange(l)}})),r.current}const kf=uo(e=>({doors:[],setDoors:t=>e({doors:t})}));function oT(e){return be({tag:"svg",attr:{viewBox:"0 0 512 512"},child:[{tag:"path",attr:{d:"M249.334 22.717c-18.64 2.424-35.677 23.574-37.043 51.49v.02c-.057 1.186-.097 2.38-.097 3.59 0 16.362 5.658 30.827 13.942 40.818l10.127 12.213-15.592 2.933c-10.75 2.025-18.622 7.702-25.373 16.978-2.285 3.14-4.384 6.707-6.31 10.62-57.54-6.44-97.91-21.06-97.91-37.952 0-17.363 42.647-31.983 102.75-37.97-.213-2.51-.323-5.057-.323-7.636v-.002c0-.84.024-1.674.047-2.51-96.43 6.77-167.298 29.15-167.3 55.71-.002 25.33 64.462 46.86 154.074 54.67-.19.742-.394 1.465-.576 2.216-2.36 9.72-4.05 20.22-5.268 31.03-.01 0-.02 0-.03.002-.418 3.653-.78 7.34-1.095 11.046l.05-.005c-1.316 15.777-1.772 31.88-1.893 46.95h35.894l2.115 28.4c-68.24-4.994-118.444-21.004-118.444-39.843 0-13.243 24.83-24.89 63.27-32.33.3-4.056.66-8.115 1.076-12.162-76.42 9.353-129.17 29.168-129.172 52.086-.002 28.17 79.71 51.643 185.098 56.768l5.94 79.77c10.5 2.648 24.84 4.162 39.017 4.068 13.79-.092 27.235-1.71 36.45-4l5.263-79.846c105.308-5.14 184.935-28.605 184.935-56.76 0-23.013-53.196-42.895-130.13-52.2.304 4.02.557 8.047.755 12.07 38.883 7.43 63.965 19.17 63.965 32.536 0 18.84-49.804 34.85-117.908 39.844l1.87-28.402h34.18c-.012-15.113-.127-31.27-1.033-47.094.01 0 .02.002.032.004-.214-3.687-.472-7.352-.782-10.986l-.02-.002c-.94-11.157-2.367-21.984-4.546-31.967-.09-.405-.184-.803-.275-1.206 89.518-7.826 153.893-29.344 153.893-54.656 0-26.787-72.076-49.332-169.77-55.887.025.895.053 1.788.053 2.688 0 2.5-.104 4.97-.304 7.407 61.19 5.836 104.61 20.61 104.61 38.2 0 16.805-39.633 31.355-96.524 37.848-2.01-4.283-4.26-8.15-6.762-11.505-6.83-9.167-15.063-14.81-27.14-16.682l-15.913-2.47 10.037-12.59c6.928-8.69 11.912-20.715 13.057-34.268h.002c.163-1.95.25-3.93.25-5.938 0-.77-.022-1.532-.048-2.29-.015-.48-.033-.958-.057-1.434h-.002c-1.48-29.745-20.507-51.3-41.076-51.3-2.528 0-3.966-.087-4.03-.08h-.003zM194.54 355.822c-97.11 6.655-168.573 29.11-168.573 55.8 0 31.932 102.243 57.815 228.367 57.815S482.7 443.555 482.7 411.623c0-26.608-71.02-49.004-167.67-55.736l-.655 9.93c60.363 6.055 103.074 20.956 103.074 38.394 0 22.81-73.032 41.298-163.12 41.298-90.088 0-163.12-18.49-163.12-41.297 0-17.533 43.18-32.502 104.07-38.493l-.74-9.895z"}}]})(e)}function Rf(e){return be({tag:"svg",attr:{fill:"currentColor",viewBox:"0 0 16 16"},child:[{tag:"path",attr:{d:"M8 15A7 7 0 1 1 8 1a7 7 0 0 1 0 14zm0 1A8 8 0 1 0 8 0a8 8 0 0 0 0 16z"}},{tag:"path",attr:{d:"M5.255 5.786a.237.237 0 0 0 .241.247h.825c.138 0 .248-.113.266-.25.09-.656.54-1.134 1.342-1.134.686 0 1.314.343 1.314 1.168 0 .635-.374.927-.965 1.371-.673.489-1.206 1.06-1.168 1.987l.003.217a.25.25 0 0 0 .25.246h.811a.25.25 0 0 0 .25-.25v-.105c0-.718.273-.927 1.01-1.486.609-.463 1.244-.977 1.244-2.056 0-1.511-1.276-2.241-2.673-2.241-1.267 0-2.655.59-2.75 2.286zm1.557 5.763c0 .533.425.927 1.01.927.609 0 1.028-.394 1.028-.927 0-.552-.42-.94-1.029-.94-.584 0-1.009.388-1.009.94z"}}]})(e)}function iT(e){return be({tag:"svg",attr:{fill:"none",viewBox:"0 0 24 24",stroke:"currentColor"},child:[{tag:"path",attr:{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2m-6 9l2 2 4-4"}}]})(e)}function lT(e){return be({tag:"svg",attr:{fill:"none",viewBox:"0 0 24 24",stroke:"currentColor"},child:[{tag:"path",attr:{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M8 5H6a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2v-1M8 5a2 2 0 002 2h2a2 2 0 002-2M8 5a2 2 0 012-2h2a2 2 0 012 2m0 0h2a2 2 0 012 2v3m2 4H10m0 0l3-3m-3 3l3 3"}}]})(e)}function aT(e){return be({tag:"svg",attr:{fill:"none",viewBox:"0 0 24 24",stroke:"currentColor"},child:[{tag:"path",attr:{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M19 7l-.867 12.142A2 2 0 0116.138 21H7.862a2 2 0 01-1.995-1.858L5 7m5 4v6m4-6v6m1-10V4a1 1 0 00-1-1h-4a1 1 0 00-1 1v3M4 7h16"}}]})(e)}const If=e=>{let t=[];if(e.groups){const r=Object.entries(e.groups);for(let n=0;n({clipboard:!1,setClipboard:t=>e({clipboard:t})})),dp=g.exports.createContext(null);dp.displayName="@mantine/modals/ModalsContext";function sT(){const e=g.exports.useContext(dp);if(!e)throw new Error("[@mantine/modals] useModals hook was called outside of context, wrap your app with ModalsProvider component");return e}var uT=Object.defineProperty,cT=Object.defineProperties,fT=Object.getOwnPropertyDescriptors,u0=Object.getOwnPropertySymbols,dT=Object.prototype.hasOwnProperty,pT=Object.prototype.propertyIsEnumerable,c0=(e,t,r)=>t in e?uT(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,_c=(e,t)=>{for(var r in t||(t={}))dT.call(t,r)&&c0(e,r,t[r]);if(u0)for(var r of u0(t))pT.call(t,r)&&c0(e,r,t[r]);return e},f0=(e,t)=>cT(e,fT(t));function gT({id:e,cancelProps:t,confirmProps:r,labels:n={cancel:"",confirm:""},closeOnConfirm:o=!0,closeOnCancel:i=!0,groupProps:l,onCancel:a,onConfirm:s,children:u}){const{cancel:c,confirm:f}=n,d=sT(),p=w=>{typeof t?.onClick=="function"&&t?.onClick(w),typeof a=="function"&&a(),i&&d.closeModal(e)},y=w=>{typeof r?.onClick=="function"&&r?.onClick(w),typeof s=="function"&&s(),o&&d.closeModal(e)};return E.createElement(E.Fragment,null,u&&E.createElement(q,{mb:"md"},u),E.createElement(jt,_c({position:"right"},l),E.createElement(Kn,f0(_c({variant:"default"},t),{onClick:p}),t?.children||c),E.createElement(Kn,f0(_c({},r),{onClick:y}),r?.children||f)))}function mT(e,t){switch(t.type){case"OPEN":return{current:t.payload,modals:[...e.modals,t.payload]};case"CLOSE":return{current:e.modals[e.modals.length-2]||null,modals:e.modals.filter(r=>r.id!==t.payload)};case"CLOSE_ALL":return{current:e.current,modals:[]};default:return e}}const[vT,Ui]=M$("mantine-modals");Ui("openModal");Ui("closeModal");Ui("closeAllModals");const rx=Ui("openConfirmModal");Ui("openContextModal");var hT=Object.defineProperty,yT=Object.defineProperties,wT=Object.getOwnPropertyDescriptors,Es=Object.getOwnPropertySymbols,nx=Object.prototype.hasOwnProperty,ox=Object.prototype.propertyIsEnumerable,d0=(e,t,r)=>t in e?hT(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Hl=(e,t)=>{for(var r in t||(t={}))nx.call(t,r)&&d0(e,r,t[r]);if(Es)for(var r of Es(t))ox.call(t,r)&&d0(e,r,t[r]);return e},p0=(e,t)=>yT(e,wT(t)),Wr=(e,t)=>{var r={};for(var n in e)nx.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&Es)for(var n of Es(e))t.indexOf(n)<0&&ox.call(e,n)&&(r[n]=e[n]);return r};function _T(e){if(!e)return{confirmProps:{},modalProps:{}};const t=e,{id:r,children:n,onCancel:o,onConfirm:i,closeOnConfirm:l,closeOnCancel:a,cancelProps:s,confirmProps:u,groupProps:c,labels:f}=t,d=Wr(t,["id","children","onCancel","onConfirm","closeOnConfirm","closeOnCancel","cancelProps","confirmProps","groupProps","labels"]);return{confirmProps:{id:r,children:n,onCancel:o,onConfirm:i,closeOnConfirm:l,closeOnCancel:a,cancelProps:s,confirmProps:u,groupProps:c,labels:f},modalProps:Hl({id:r},d)}}function ST({children:e,modalProps:t,labels:r,modals:n}){const[o,i]=g.exports.useReducer(mT,{modals:[],current:null}),l=w=>{o.modals.forEach(v=>{var m,h,_,b;v.type==="confirm"&&w&&((h=(m=v.props)==null?void 0:m.onCancel)==null||h.call(m)),(b=(_=v.props)==null?void 0:_.onClose)==null||b.call(_)}),i({type:"CLOSE_ALL"})},a=w=>{var v=w,{modalId:m}=v,h=Wr(v,["modalId"]);const _=m||Al();return i({type:"OPEN",payload:{id:_,type:"content",props:h}}),_},s=w=>{var v=w,{modalId:m}=v,h=Wr(v,["modalId"]);const _=m||Al();return i({type:"OPEN",payload:{id:_,type:"confirm",props:h}}),_},u=(w,v)=>{var m=v,{modalId:h}=m,_=Wr(m,["modalId"]);const b=h||Al();return i({type:"OPEN",payload:{id:b,type:"context",props:_,ctx:w}}),b},c=(w,v)=>{var m,h,_,b;if(o.modals.length<=1){l(v);return}const O=o.modals.find(x=>x.id===w);O?.type==="confirm"&&v&&((h=(m=O.props)==null?void 0:m.onCancel)==null||h.call(m)),(b=(_=O?.props)==null?void 0:_.onClose)==null||b.call(_),i({type:"CLOSE",payload:O.id})};vT({openModal:a,openConfirmModal:s,openContextModal:w=>{var v=w,{modal:m}=v,h=Wr(v,["modal"]);return u(m,h)},closeModal:c,closeAllModals:l});const f={modals:o.modals,openModal:a,openConfirmModal:s,openContextModal:u,closeModal:c,closeAll:l},d=()=>{var w;switch((w=o.current)==null?void 0:w.type){case"context":{const v=o.current.props,{innerProps:m}=v,h=Wr(v,["innerProps"]),_=n[o.current.ctx];return{modalProps:h,content:S(_,{innerProps:m,context:f,id:o.current.id})}}case"confirm":{const{modalProps:v,confirmProps:m}=_T(o.current.props);return{modalProps:v,content:S(gT,{...p0(Hl({},m),{id:o.current.id,labels:o.current.props.labels||r})})}}case"content":{const v=o.current.props,{children:m}=v;return{modalProps:Wr(v,["children"]),content:S(it,{children:m})}}default:return{modalProps:{},content:null}}},{modalProps:p,content:y}=d();return U(dp.Provider,{value:f,children:[S(mu,{...p0(Hl(Hl({},t),p),{opened:o.modals.length>0,onClose:()=>c(o.current.id)}),children:y}),e]})}const bT=({data:e})=>{const t=Bi(),r=tx(o=>o.setClipboard),n=wu(o=>o.setVisible);return U(et,{position:"right-start",width:200,children:[S(et.Target,{children:S(nt,{label:"Door actions",children:S($t,{color:"blue.4",variant:"transparent",children:S(lD,{size:24})})})}),U(et.Dropdown,{children:[S(et.Item,{icon:S(yu,{size:18}),onClick:()=>{K.setState(If(e.row.original),!0),t("/settings/general")},children:"Settings"}),S(et.Item,{icon:S(lT,{size:18}),onClick:()=>{r(If(e.row.original)),xr("notify","Settings copied")},children:"Copy settings"}),S(et.Item,{icon:S(oT,{size:18}),onClick:()=>{n(!1),xr("teleportToDoor",e.row.getValue("id"))},children:"Teleport to door"}),S(et.Item,{color:"red",icon:S(Wi,{size:18}),onClick:()=>rx({title:"Confirm deletion",centered:!0,withCloseButton:!1,children:U(mt,{children:["Are you sure you want to delete",S(mt,{component:"span",weight:700,children:` ${e.row.getValue("name")}`}),"?"]}),labels:{confirm:"Confirm",cancel:"Cancel"},confirmProps:{color:"red"},onConfirm:()=>{xr("deleteDoor",e.row.getValue("id"))}}),children:"Delete door"})]})]})},xT=()=>{const[e,t]=g.exports.useState([]),[r,n]=g.exports.useState(1),o=Pf(s=>s.debouncedValue),i=kf(s=>s.doors),l=g.exports.useMemo(()=>[{id:"id",header:"ID",accessorKey:"id",cell:s=>s.getValue(),enableHiding:!1,enableGlobalFilter:!1},{id:"name",header:"Name",accessorKey:"name",cell:s=>s.getValue(),enableHiding:!1},{id:"zone",header:"Zone",accessorKey:"zone",cell:s=>s.getValue(),enableHiding:!1},{id:"options-menu",cell:s=>S(bT,{data:s})}],[]),a=nT({data:i,columns:l,initialState:{pagination:{pageSize:8,pageIndex:0}},state:{sorting:e,globalFilter:o},onGlobalFilterChange:Pf(s=>s.setValue),onSortingChange:t,getCoreRowModel:GD(),getSortedRowModel:QD(),getFilteredRowModel:KD(),getPaginationRowModel:JD()});return g.exports.useEffect(()=>{a.setPageIndex(r-1)},[r,i]),U(Tt,{justify:"space-between",align:"center",sx:{height:"100%",paddingBottom:16},spacing:0,children:[a.getFilteredRowModel().rows.length>0?U(db,{children:[S("thead",{children:a.getHeaderGroups().map(s=>S("tr",{children:s.headers.map(u=>S("th",{children:S(ou,{onClick:u.column.getToggleSortingHandler(),children:U(jt,{children:[S(mt,{children:s0(u.column.columnDef.header,u.getContext())}),u.column.getIsSorted()==="desc"?S(oD,{}):u.column.getIsSorted()==="asc"?S(iD,{}):u.column.getCanHide()?S(it,{}):S(sD,{})]})})},u.id))},s.id))}),S("tbody",{children:a.getRowModel().rows.map(s=>S("tr",{children:s.getAllCells().map(u=>S("td",{children:s0(u.column.columnDef.cell,u.getContext())},u.id))},s.id))})]}):S(J_,{sx:{height:"100%"},children:U(Tt,{align:"center",children:[S(Ub,{size:48}),S(mt,{size:"lg",children:"No results found"})]})}),a.getPageCount()>1&&S(rb,{page:r,total:a.getPageCount(),onChange:s=>n(s)})]})},PT=()=>U(Tt,{sx:{height:"100%"},children:[S(pD,{}),S(xT,{})]}),Lo=({label:e,type:t,infoCircle:r,span:n,value:o,setValue:i})=>S(gu.Col,{span:n||1,children:S(q,{children:t==="text"?S(Tr,{value:o,onChange:l=>i(l.target.value),label:e,rightSection:r&&S(nt,{label:r,withArrow:!0,arrowSize:10,multiline:!0,width:200,children:S(bf,{variant:"light",mr:10,children:S(Rf,{size:18})})})}):S($i,{label:e,step:.1,precision:1,value:typeof o=="number"?o:void 0,onChange:l=>i(l),hideControls:!0,rightSection:r&&S(nt,{label:r,withArrow:!0,arrowSize:10,multiline:!0,width:200,children:S(bf,{variant:"light",mr:10,children:S(Rf,{size:18})})})})})}),$T=()=>{const e=K(c=>c.name),t=K(c=>c.passcode),r=K(c=>c.autolock),n=K(c=>c.maxDistance),o=K(c=>c.doorRate),i=_e(c=>c.setName),l=_e(c=>c.setPasscode),a=_e(c=>c.setAutolock),s=_e(c=>c.setMaxDistance),u=_e(c=>c.setDoorRate);return S(it,{children:U(gu,{columns:2,sx:{fontSize:16},children:[S(Lo,{label:"Door name",type:"text",value:e||"",setValue:c=>i(c)}),S(Lo,{label:"Passcode",type:"text",value:t||"",setValue:c=>l(c)}),S(Lo,{label:"Autolock Interval",type:"number",value:r||0,setValue:c=>a(c),infoCircle:"Time in seconds after which the door will be locked"}),S(Lo,{label:"Interact Distance",type:"number",value:n||0,setValue:c=>s(c),infoCircle:"Controls the distance from which the player can interact with the door"}),S(Lo,{label:"Door Rate",type:"number",span:2,value:o||0,setValue:c=>u(c),infoCircle:"Speed the automatic door will move at"})]})})},_n=({infoCircle:e,label:t,value:r,toggle:n})=>U(jt,{spacing:8,align:"center",children:[S(np,{label:t,checked:r,onChange:()=>n()}),S(nt,{label:e,withArrow:!0,arrowSize:10,multiline:!0,width:200,children:S(q,{sx:{display:"flex"},children:S(Rf,{size:18})})})]}),OT=()=>{const e=K(a=>a.state),t=K(a=>a.doors),r=K(a=>a.auto),n=K(a=>a.lockpick),o=K(a=>a.hideUi),i=K(a=>a.holdOpen),l=_e(a=>a.toggleCheckbox);return S(it,{children:U(ab,{cols:2,pt:16,children:[S(_n,{label:"Locked",infoCircle:"Sets whether the targeting door is locked by default",value:e||!1,toggle:()=>l("state")}),S(_n,{label:"Double",infoCircle:"Enable if the targeting door is a double door",value:t||!1,toggle:()=>l("doors")}),S(_n,{label:"Automatic",infoCircle:"Enable if the targeting door is moving automatically (Garage, poles, etc...)",value:r||!1,toggle:()=>l("auto")}),S(_n,{label:"Lockpick",infoCircle:"Enables the targeting door to be lockpicked. Can define skill check difficulties in Lockpick tab, otherwise uses config defaults",value:n||!1,toggle:()=>l("lockpick")}),S(_n,{label:"Hide UI",infoCircle:"Hides UI indicators for the targeting door",value:o||!1,toggle:()=>l("hideUi")}),S(_n,{label:"Hold Open",infoCircle:"Sets whether the targeting door(s) should stay open while unlocked",value:i||!1,toggle:()=>l("holdOpen")})]})})},CT=()=>S(Tt,{justify:"space-between",sx:{height:"100%"},children:U(q,{children:[S($T,{}),S(OT,{})]})}),ET=()=>{const e=K(o=>o.characters),t=_e(o=>o.setCharacters),r=(o,i)=>{t(l=>l.map((a,s)=>i===s?o:a))},n=o=>{t(i=>i.filter((l,a)=>a!==o))};return S(it,{children:e.map((o,i)=>U(jt,{position:"center",mt:i===0?0:16,noWrap:!0,spacing:16,sx:{fontSize:16},children:[S(Tr,{sx:{width:"100%"},placeholder:"Character Id",value:o,onChange:l=>r(l.target.value,i)}),S(nt,{label:"Delete row",children:S($t,{color:"red.4",variant:"transparent",onClick:()=>n(i),children:S(Wi,{size:24})})})]},`group-${i}`))})},_u=({children:e,setter:t})=>S(Tt,{justify:"space-between",align:"center",sx:{height:"100%"},children:U(q,{sx:{width:"100%",overflowY:"auto",height:410},children:[e,S(nt,{label:"Create a new row",withArrow:!0,arrowSize:10,children:S(Kn,{mt:16,fullWidth:!0,variant:"light",onClick:t,children:S(Wb,{size:24})})})]})}),kT=()=>{const e=_e(t=>t.setCharacters);return g.exports.useEffect(()=>()=>{e(t=>t.filter((r,n)=>r!==""||n===0))},[]),S(_u,{setter:()=>e(t=>[...t,""]),children:S(ET,{})})},RT=()=>{const e=K(o=>o.groups),t=_e(o=>o.setGroups),r=(o,i,l)=>{t(a=>a.map((s,u)=>i===u?{...s,[l]:o}:s))},n=o=>{t(i=>i.filter((l,a)=>a!==o))};return S(it,{children:e.map((o,i)=>U(jt,{position:"center",mt:i===0?0:16,noWrap:!0,spacing:16,sx:{fontSize:16},children:[S(Tr,{sx:{width:"100%"},placeholder:"Group",value:o.name,onChange:l=>r(l.target.value,i,"name")}),S($i,{sx:{width:"100%"},placeholder:"Grade",value:o.grade,onChange:l=>r(l,i,"grade")}),S(nt,{label:"Delete row",children:S($t,{color:"red.4",variant:"transparent",onClick:()=>n(i),children:S(Wi,{size:24})})})]},`group-${i}`))})},IT=()=>{const e=_e(t=>t.setGroups);return g.exports.useEffect(()=>()=>{e(t=>t.filter((r,n)=>r.name!==""||r.grade!==null||n===0))},[]),S(_u,{setter:()=>e(t=>[...t,{name:"",grade:null}]),children:S(RT,{})})};var g0=function e(t,r){if(t===r)return!0;if(t&&r&&typeof t=="object"&&typeof r=="object"){if(t.constructor!==r.constructor)return!1;var n,o,i;if(Array.isArray(t)){if(n=t.length,n!=r.length)return!1;for(o=n;o--!==0;)if(!e(t[o],r[o]))return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if(i=Object.keys(t),n=i.length,n!==Object.keys(r).length)return!1;for(o=n;o--!==0;)if(!Object.prototype.hasOwnProperty.call(r,i[o]))return!1;for(o=n;o--!==0;){var l=i[o];if(!e(t[l],r[l]))return!1}return!0}return t!==t&&r!==r};function Nf(e){return e===null||typeof e!="object"?{}:Object.keys(e).reduce((t,r)=>{const n=e[r];return n!=null&&n!==!1&&(t[r]=n),t},{})}var NT=Object.defineProperty,m0=Object.getOwnPropertySymbols,zT=Object.prototype.hasOwnProperty,DT=Object.prototype.propertyIsEnumerable,v0=(e,t,r)=>t in e?NT(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,TT=(e,t)=>{for(var r in t||(t={}))zT.call(t,r)&&v0(e,r,t[r]);if(m0)for(var r of m0(t))DT.call(t,r)&&v0(e,r,t[r]);return e};function h0(e,t){if(t===null||typeof t!="object")return{};const r=TT({},t);return Object.keys(t).forEach(n=>{n.includes(`${String(e)}.`)&&delete r[n]}),r}const MT="__MANTINE_FORM_INDEX__";function y0(e,t){return t?typeof t=="boolean"?t:Array.isArray(t)?t.includes(e.replace(/[.][0-9]/g,`.${MT}`)):!1:!1}function Vt(e){if(typeof e!="object")return e;var t,r,n=Object.prototype.toString.call(e);if(n==="[object Object]"){if(e.constructor!==Object&&typeof e.constructor=="function"){r=new e.constructor;for(t in e)e.hasOwnProperty(t)&&r[t]!==e[t]&&(r[t]=Vt(e[t]))}else{r={};for(t in e)t==="__proto__"?Object.defineProperty(r,t,{value:Vt(e[t]),configurable:!0,enumerable:!0,writable:!0}):r[t]=Vt(e[t])}return r}if(n==="[object Array]"){for(t=e.length,r=Array(t);t--;)r[t]=Vt(e[t]);return r}return n==="[object Set]"?(r=new Set,e.forEach(function(o){r.add(Vt(o))}),r):n==="[object Map]"?(r=new Map,e.forEach(function(o,i){r.set(Vt(i),Vt(o))}),r):n==="[object Date]"?new Date(+e):n==="[object RegExp]"?(r=new RegExp(e.source,e.flags),r.lastIndex=e.lastIndex,r):n==="[object DataView]"?new e.constructor(Vt(e.buffer)):n==="[object ArrayBuffer]"?e.slice(0):n.slice(-6)==="Array]"?new e.constructor(e):e}function ix(e){return typeof e!="string"?[]:e.split(".")}function Su(e,t,r){const n=ix(e);if(n.length===0)return r;const o=Vt(r);if(n.length===1)return o[n[0]]=t,o;let i=o[n[0]];for(let l=1;l0,errors:t}}function zf(e,t,r="",n={}){return typeof e!="object"||e===null?n:Object.keys(e).reduce((o,i)=>{const l=e[i],a=`${r===""?"":`${r}.`}${i}`,s=pr(a,t);let u=!1;return typeof l=="function"&&(o[a]=l(s,t,a)),typeof l=="object"&&Array.isArray(s)&&(u=!0,s.forEach((c,f)=>zf(l,t,`${a}.${f}`,o))),typeof l=="object"&&typeof s=="object"&&s!==null&&(u||zf(l,t,a,o)),o},n)}function Df(e,t){return w0(typeof e=="function"?e(t):zf(e,t))}function $l(e,t,r){if(typeof e!="string")return{hasError:!1,error:null};const n=Df(t,r),o=Object.keys(n.errors).find(i=>e.split(".").every((l,a)=>l===i.split(".")[a]));return{hasError:!!o,error:o?n.errors[o]:null}}function jT(e,{from:t,to:r},n){const o=pr(e,n);if(!Array.isArray(o))return n;const i=[...o],l=o[t];return i.splice(t,1),i.splice(r,0,l),Su(e,i,n)}function LT(e,t,r){const n=pr(e,r);return Array.isArray(n)?Su(e,n.filter((o,i)=>i!==t),r):r}function FT(e,t,r,n){const o=pr(e,n);if(!Array.isArray(o))return n;const i=[...o];return i.splice(typeof r=="number"?r:i.length,0,t),Su(e,i,n)}function _0(e,t){const r=Object.keys(e);if(typeof t=="string"){const n=r.filter(o=>o.includes(`${t}.`));return e[t]||n.some(o=>e[o])||!1}return r.some(n=>e[n])}function AT(e){return t=>{if(!t)e(t);else if(typeof t=="function")e(t);else if(typeof t=="object"&&"nativeEvent"in t){const{currentTarget:r}=t;r instanceof HTMLInputElement?r.type==="checkbox"?e(r.checked):e(r.value):(r instanceof HTMLTextAreaElement||r instanceof HTMLSelectElement)&&e(r.value)}else e(t)}}var VT=Object.defineProperty,HT=Object.defineProperties,BT=Object.getOwnPropertyDescriptors,S0=Object.getOwnPropertySymbols,WT=Object.prototype.hasOwnProperty,UT=Object.prototype.propertyIsEnumerable,b0=(e,t,r)=>t in e?VT(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Sn=(e,t)=>{for(var r in t||(t={}))WT.call(t,r)&&b0(e,r,t[r]);if(S0)for(var r of S0(t))UT.call(t,r)&&b0(e,r,t[r]);return e},Sc=(e,t)=>HT(e,BT(t));function lx({initialValues:e={},initialErrors:t={},initialDirty:r={},initialTouched:n={},clearInputErrorOnChange:o=!0,validateInputOnChange:i=!1,validateInputOnBlur:l=!1,transformValues:a=u=>u,validate:s}={}){const[u,c]=g.exports.useState(n),[f,d]=g.exports.useState(r),[p,y]=g.exports.useState(e),[w,v]=g.exports.useState(Nf(t)),m=g.exports.useRef(e),h=k=>{m.current=k},_=g.exports.useCallback(()=>c({}),[]),b=k=>{h(k||p),d({})},O=g.exports.useCallback(k=>v(M=>Nf(typeof k=="function"?k(M):k)),[]),x=g.exports.useCallback(()=>v({}),[]),P=g.exports.useCallback(()=>{y(e),x(),b(e),_()},[]),$=g.exports.useCallback((k,M)=>O(G=>Sc(Sn({},G),{[k]:M})),[]),C=g.exports.useCallback(k=>O(M=>{if(typeof k!="string")return M;const G=Sn({},M);return delete G[k],G}),[]),I=g.exports.useCallback(k=>d(M=>{if(typeof k!="string")return M;const G=h0(k,M);return delete G[k],G}),[]),z=g.exports.useCallback((k,M)=>{const G=y0(k,i);I(k),c(Z=>Sc(Sn({},Z),{[k]:!0})),y(Z=>{const ze=Su(k,M,Z);if(G){const ae=$l(k,s,ze);ae.hasError?$(k,ae.error):C(k)}return ze}),!G&&o&&$(k,null)},[]),D=g.exports.useCallback(k=>{y(M=>{const G=typeof k=="function"?k(M):k;return Sn(Sn({},M),G)}),o&&x()},[]),j=g.exports.useCallback((k,M)=>{I(k),y(G=>jT(k,M,G))},[]),B=g.exports.useCallback((k,M)=>{I(k),y(G=>LT(k,M,G)),v(G=>h0(k,G))},[]),V=g.exports.useCallback((k,M,G)=>{I(k),y(Z=>FT(k,M,G,Z))},[]),W=g.exports.useCallback(()=>{const k=Df(s,p);return v(k.errors),k},[p,s]),re=g.exports.useCallback(k=>{const M=$l(k,s,p);return M.hasError?$(k,M.error):C(k),M},[p,s]),se=(k,{type:M="input",withError:G=M==="input",withFocus:Z=!0}={})=>{const ae={onChange:AT(Ae=>z(k,Ae))};return G&&(ae.error=w[k]),M==="checkbox"?ae.checked=pr(k,p):ae.value=pr(k,p),Z&&(ae.onFocus=()=>c(Ae=>Sc(Sn({},Ae),{[k]:!0})),ae.onBlur=()=>{if(y0(k,l)){const Ae=$l(k,s,p);Ae.hasError?$(k,Ae.error):C(k)}}),ae},ie=(k,M)=>G=>{G?.preventDefault();const Z=W();Z.hasErrors?M?.(Z.errors,p,G):k(a(p),G)},Ne=g.exports.useCallback(k=>{k.preventDefault(),P()},[]),R=k=>{if(Object.keys(f).length>0)return _0(f,k);if(k){const G=pr(k,p),Z=pr(k,m.current);return!g0(G,Z)}return!g0(p,m.current)},T=g.exports.useCallback(k=>_0(u,k),[u]),A=g.exports.useCallback(k=>k?!$l(k,s,p).hasError:!Df(s,p).hasErrors,[p,s]);return{values:p,errors:w,setValues:D,setErrors:O,setFieldValue:z,setFieldError:$,clearFieldError:C,clearErrors:x,reset:P,validate:W,validateField:re,reorderListItem:j,removeListItem:B,insertListItem:V,getInputProps:se,onSubmit:ie,onReset:Ne,isDirty:R,isTouched:T,setTouched:c,setDirty:d,resetTouched:_,resetDirty:b,isValid:A}}const GT=({modal:e,setModal:t})=>{const r=K(a=>a.items),n=_e(a=>a.setItems),o=g.exports.useMemo(()=>r[e.index],[e,r]),i=lx({initialValues:{metadata:o.metadata,remove:o.remove}}),l=a=>{t(s=>({...s,opened:!1})),n(s=>s.map((u,c)=>c===e.index?{...u,metadata:a.metadata,remove:a.remove}:u))};return S("form",{onSubmit:i.onSubmit(a=>l(a)),children:U(Tt,{children:[S(Tr,{label:"Metadata type",defaultValue:o.metadata,...i.getInputProps("metadata")}),S(np,{label:"Remove on use",defaultChecked:o.remove,...i.getInputProps("remove")}),S(Kn,{uppercase:!0,variant:"light",type:"submit",children:"Confirm"})]})})},YT=()=>{const e=K(l=>l.items),t=_e(l=>l.setItems),[r,n]=g.exports.useState({opened:!1,index:0}),o=(l,a)=>{const s=[...e];switch(l.target.id){case"name":s[a].name=l.target.value;break}t(()=>s)},i=l=>{t(a=>a.filter((s,u)=>u!==l))};return U(q,{children:[e.length>0&&S(it,{children:e.map((l,a)=>U(jt,{sx:{width:"100%"},position:"apart",spacing:16,mt:a===0?void 0:16,children:[S(Tr,{sx:{width:"80%"},value:l.name||"",id:"name",placeholder:"Item",onChange:s=>o(s,a)}),S(nt,{label:"Item options",children:S($t,{color:"blue.4",variant:"transparent",onClick:()=>n({opened:!0,index:a}),children:S(yu,{size:24})})}),S(nt,{label:"Delete row",children:S($t,{color:"red.4",variant:"transparent",onClick:()=>i(a),children:S(Wi,{size:24})})})]},`item-field-${a}`))}),S(mu,{opened:r.opened,onClose:()=>n({...r,opened:!1}),transition:"fade",title:"Item options",centered:!0,size:"xs",withCloseButton:!1,children:S(GT,{modal:r,setModal:n})})]})},XT=()=>{const e=_e(t=>t.setItems);return g.exports.useEffect(()=>()=>{e(t=>t.filter((r,n)=>n===0||r.name!==""))},[]),S(_u,{setter:()=>e(t=>[...t,{name:"",metadata:"",remove:!1}]),children:S(YT,{})})},qT=()=>{const e=_e(i=>i.sounds),t=K(i=>i.lockSound),r=K(i=>i.unlockSound),n=_e(i=>i.setLockSound),o=_e(i=>i.setUnlockSound);return U(Tt,{children:[S(Oi,{data:e,label:"Lock sound",value:t||"",searchable:!0,clearable:!0,nothingFound:"No such sound",onChange:i=>n(i)}),S(Oi,{data:e,label:"Unlock sound",value:r||"",searchable:!0,clearable:!0,nothingFound:"No such sound",onChange:i=>o(i)})]})},KT=()=>{const e=Bi(),t=tx(o=>o.clipboard),r=wu(o=>o.setVisible),n=()=>{const o={...K.getState()};if(o.name===""&&(o.name=null),o.passcode===""&&(o.passcode=null),o.lockSound===""&&(o.lockSound=null),o.unlockSound===""&&(o.unlockSound=null),o.autolock=o.autolock||null,o.maxDistance=o.maxDistance||2,o.doorRate=o.doorRate?o.doorRate+0:null,o.auto=o.auto||null,o.lockpick=o.lockpick||null,o.hideUi=o.hideUi||null,o.holdOpen=o.holdOpen||null,o.items&&o.items.length>0){const i=[];for(let l=0;l0){const i=[];for(let l=0;l0){const i={};for(let l=0;l0){const i=[];for(let l=0;ln(),fullWidth:!0,children:"Confirm door"}),S(nt,{label:t?"Apply copied settings":"No door settings copied",withArrow:!0,arrowSize:10,children:S($t,{variant:"outline",disabled:!t,size:"lg",ml:16,sx:{width:36,height:36},color:"blue",onClick:()=>{K.setState({name:"",passcode:t.passcode,autolock:t.autolock,items:t.items,characters:t.characters,groups:t.groups,maxDistance:t.maxDistance,doorRate:t.doorRate,lockSound:t.lockSound,unlockSound:t.unlockSound,auto:t.auto,state:t.state,lockpick:t.lockpick,hideUi:t.hideUi,doors:t.doors,lockpickDifficulty:t.lockpickDifficulty,holdOpen:t.holdOpen},!0),xr("notify","Settings applied")},children:S(iT,{size:20})})}),S($t,{variant:"outline",size:"lg",ml:16,sx:{width:36,height:36},color:"red",disabled:!K.getState().id,onClick:()=>rx({title:"Confirm deletion",centered:!0,withCloseButton:!1,children:U(mt,{children:["Are you sure you want to delete",S(mt,{component:"span",weight:700,children:` ${K.getState().name}`}),"?"]}),labels:{confirm:"Confirm",cancel:"Cancel"},confirmProps:{color:"red"},onConfirm:()=>{xr("deleteDoor",K.getState().id),e("/")}}),children:S(aT,{size:20})})]})},QT=({selectData:e,setModal:t,modal:r})=>{const[n,o]=g.exports.useState(null),i=K(c=>c.lockpickDifficulty),l=_e(c=>c.setLockpickDifficulty),a=g.exports.useMemo(()=>i[r.index],[r,i]);g.exports.useEffect(()=>o(typeof a=="string"?a:"custom"),[a]);const s=lx({initialValues:{select:n,areaSize:typeof a=="string"?null:a.areaSize,speedMultiplier:typeof a=="string"?null:a.speedMultiplier},validate:{select:c=>c===null?"Difficulty is required":null,areaSize:(c,f)=>c===null&&f.select==="custom"?"Area size is required":null,speedMultiplier:(c,f)=>c===null&&f.select==="custom"?"Speed multiplier is required":null}});g.exports.useEffect(()=>s.setFieldValue("select",n),[n]);const u=c=>{t(d=>({...d,opened:!1}));const f=c.select==="custom"?{areaSize:c.areaSize,speedMultiplier:c.speedMultiplier}:c.select;!f||l(d=>{const p=[...d];return f&&(p[r.index]=f),p})};return S("form",{onSubmit:s.onSubmit(c=>u(c)),children:U(Tt,{children:[S(Oi,{data:e,placeholder:"Difficulty",...s.getInputProps("select"),value:n,onChange:o,required:!0}),S($i,{label:"Area size",defaultValue:typeof a=="object"?a.areaSize:null,description:"Skill check area size in degrees",disabled:n!=="custom",max:360,hideControls:!0,required:n==="custom",...s.getInputProps("areaSize")}),S($i,{label:"Speed multiplier",description:"Number the indicator speed will be multiplied by",disabled:n!=="custom",defaultValue:typeof a=="object"?a.speedMultiplier:null,hideControls:!0,precision:2,required:n==="custom",...s.getInputProps("speedMultiplier")}),S(Kn,{type:"submit",uppercase:!0,variant:"light",children:"Confirm"})]})})},x0=[{label:"Easy",value:"easy"},{label:"Medium",value:"medium"},{label:"Hard",value:"hard"},{label:"Custom",value:"custom"}],ZT=()=>{const e=K(i=>i.lockpickDifficulty),t=_e(i=>i.setLockpickDifficulty),[r,n]=g.exports.useState({opened:!1,index:0}),o=i=>{t(l=>l.filter((a,s)=>s!==i))};return U(it,{children:[e.map((i,l)=>U(jt,{sx:{width:"100%"},spacing:16,mt:l===0?void 0:16,position:"apart",children:[S(Oi,{data:x0,value:typeof i=="string"?i:"custom",readOnly:!0,placeholder:"Edit row to select value",sx:{width:"80%"}}),S(nt,{label:"Edit row",children:S($t,{color:"blue.4",variant:"transparent",onClick:()=>n({opened:!0,index:l}),children:S(yu,{size:24})})}),S(nt,{label:"Delete row",children:S($t,{color:"red.4",variant:"transparent",onClick:()=>o(l),children:S(Wi,{size:24})})})]},`${typeof i=="string"?i:i.areaSize}-${l}`)),S(mu,{opened:r.opened,onClose:()=>n({...r,opened:!1}),transition:"fade",title:"Lockpick difficulty",centered:!0,size:"xs",withCloseButton:!1,children:S(QT,{selectData:x0,setModal:n,modal:r})})]})},JT=()=>{const e=_e(t=>t.setLockpickDifficulty);return g.exports.useEffect(()=>()=>{e(t=>t.filter((r,n)=>n===0||r!==""))},[]),S(_u,{setter:()=>e(t=>[...t,""]),children:S(ZT,{})})},e7=()=>{const e=Bi(),t=ap(),r=K(n=>n.lockpick);return S(it,{children:U(q,{sx:{height:"100%",display:"flex"},children:[S(Je,{orientation:"vertical",color:"blue",sx:{height:"100%"},value:t.pathname.substring(10),onTabChange:n=>e(`/settings/${n}`),children:U(Je.List,{children:[S(Je.Tab,{value:"back",onClick:()=>e("/"),icon:S(eD,{size:20}),children:"Doors"}),S(Je.Tab,{value:"general",icon:S(yu,{size:20}),children:"General"}),S(Je.Tab,{value:"characters",icon:S(uD,{size:20}),children:"Characters"}),S(Je.Tab,{value:"groups",icon:S(nD,{size:20}),children:"Groups"}),S(Je.Tab,{value:"items",icon:S(rD,{size:20}),children:"Items"}),S(Je.Tab,{value:"lockpick",disabled:!r,icon:S(aD,{size:20}),children:"Lockpick"}),S(Je.Tab,{value:"sound",icon:S(tD,{size:20}),children:"Sound"})]})}),U(Tt,{p:16,sx:{width:"100%"},justify:"space-between",children:[U(Ab,{children:[S(Bt,{path:"/general",element:S(CT,{})}),S(Bt,{path:"/characters",element:S(kT,{})}),S(Bt,{path:"/groups",element:S(IT,{})}),S(Bt,{path:"/items",element:S(XT,{})}),S(Bt,{path:"/sound",element:S(qT,{})}),S(Bt,{path:"/lockpick",element:S(JT,{})})]}),S(KT,{})]})]})})},t7=["Escape"],r7=(e,t)=>{const r=g.exports.useRef(Vb);g.exports.useEffect(()=>{r.current=e},[e]),g.exports.useEffect(()=>{const n=o=>{t7.includes(o.code)&&(r.current(!1),t&&t(),xr("exit"))};return window.addEventListener("keyup",n),()=>window.removeEventListener("keyup",n)},[])},n7=Q(e=>({container:{width:"100%",height:"100%",display:"flex",justifyContent:"center",alignItems:"center"},main:{width:700,height:500,backgroundColor:e.colors.dark[8],borderRadius:e.radius.sm},search:{width:"40%",transition:"300ms","&:focus-within":{width:"50%"}}})),o7=()=>{const{classes:e}=n7(),t=_e(a=>a.setSounds),[r,n]=wu(a=>[a.visible,a.setVisible]),o=kf(a=>a.doors),i=kf(a=>a.setDoors),l=Bi();return Sl("playSound",async a=>{const s=new Audio(`./sounds/${a.sound}.ogg`);s.volume=a.volume,await s.play()}),Sl("setSoundFiles",a=>t(a)),Sl("setVisible",a=>{if(n(!0),a===void 0)return l("/");for(let s=0;s{if(typeof a=="number")return i(o.filter(s=>s.id!==a));if(a.hasOwnProperty("id")){let s=o.length;for(let u=0;uS(q,{className:e.main,style:a,children:U(Ab,{children:[S(Bt,{path:"/",element:S(PT,{})}),S(Bt,{path:"/settings/*",element:S(e7,{})})]})})})})},i7={colorScheme:"dark",fontFamily:"Roboto",components:{Tooltip:{defaultProps:{transition:"pop"}}}};if(Xz()){const e=document.getElementById("root");e.style.backgroundImage='url("https://i.imgur.com/3pzRj9n.png")',e.style.backgroundSize="cover",e.style.backgroundRepeat="no-repeat",e.style.backgroundPosition="center"}S$.render(S(E.StrictMode,{children:S(F1,{withNormalizeCSS:!0,withGlobalStyles:!0,theme:i7,children:S(ST,{modalProps:{transition:"slide-up"},children:S(Yz,{children:S(o7,{})})})})}),document.getElementById("root")); diff --git a/resources/[housing]/ox_doorlock/web/build/index.html b/resources/[housing]/ox_doorlock/web/build/index.html new file mode 100644 index 000000000..4e4d506d3 --- /dev/null +++ b/resources/[housing]/ox_doorlock/web/build/index.html @@ -0,0 +1,15 @@ + + + + + + + NUI React Boilerplate + + + + +
+ + + diff --git a/resources/[housing]/ox_doorlock/web/build/sounds/button-remote.ogg b/resources/[housing]/ox_doorlock/web/build/sounds/button-remote.ogg new file mode 100644 index 000000000..46570236b Binary files /dev/null and b/resources/[housing]/ox_doorlock/web/build/sounds/button-remote.ogg differ diff --git a/resources/[housing]/ox_doorlock/web/build/sounds/door-bolt-4.ogg b/resources/[housing]/ox_doorlock/web/build/sounds/door-bolt-4.ogg new file mode 100644 index 000000000..61a43bbd0 Binary files /dev/null and b/resources/[housing]/ox_doorlock/web/build/sounds/door-bolt-4.ogg differ diff --git a/resources/[housing]/ox_doorlock/web/build/sounds/metal-locker.ogg b/resources/[housing]/ox_doorlock/web/build/sounds/metal-locker.ogg new file mode 100644 index 000000000..deea9def3 Binary files /dev/null and b/resources/[housing]/ox_doorlock/web/build/sounds/metal-locker.ogg differ diff --git a/resources/[housing]/ox_doorlock/web/build/sounds/metallic-creak.ogg b/resources/[housing]/ox_doorlock/web/build/sounds/metallic-creak.ogg new file mode 100644 index 000000000..9c6623319 Binary files /dev/null and b/resources/[housing]/ox_doorlock/web/build/sounds/metallic-creak.ogg differ diff --git a/resources/[inventory]/tgiann-inventory/configs/configStashes.lua b/resources/[inventory]/tgiann-inventory/configs/configStashes.lua index 814e7af61..93a09d16a 100644 --- a/resources/[inventory]/tgiann-inventory/configs/configStashes.lua +++ b/resources/[inventory]/tgiann-inventory/configs/configStashes.lua @@ -31,13 +31,27 @@ config.stashes = { owner = false, jobs = { ambulance = true, police = { 1, 2, 3, 4, 5, 6, 7, 8, 9 } } -- all ranks for ambulance job, only 9 ranks for police job }, + + ---- NORDIS HAUS ---- + { - coords = vec3(443.6447, -975.7927, 30.6896), - textUiLabel = 'Open Global Stash', - name = 'globalstash', -- uniq name - label = 'Global Stash', - slots = 70, + coords = vec3(-1238.3628, 838.1411, 192.8895, 330.3338), + textUiLabel = 'öffnen', + name = 'nordisideboard', -- uniq name + label = 'Sideboard', + slots = 10, weight = 70000, }, + { + coords = vec3(-1230.7251, 839.1404, 192.8895, 61.2964), + textUiLabel = 'öffnen', + name = 'nordisfridge', -- uniq name + label = 'Kühlschrank', + slots = 20, + weight = 70000, + }, + + + } }