@purpurds/tabs 7.3.0 → 7.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/LICENSE.txt CHANGED
@@ -1,5 +1,5 @@
1
1
  Name: @purpurds/icon
2
- Version: 7.2.0
2
+ Version: 7.3.1
3
3
  License: AGPL-3.0-only
4
4
  Private: false
5
5
 
package/dist/styles.css CHANGED
@@ -1 +1 @@
1
- ._purpur-tab-content_1ugbi_1{position:relative}._purpur-tab-content_1ugbi_1:focus-visible{outline:0}._purpur-tab-content_1ugbi_1:focus-visible:before{content:"";position:absolute;top:0;right:0;bottom:0;left:0;outline:var(--purpur-border-width-sm) solid var(--purpur-color-border-interactive-focus);border-radius:var(--purpur-border-radius-xs);pointer-events:none}._purpur-tab-content--force-mount_1ugbi_15[data-state=inactive]{display:none}._purpur-tab-header_1thzh_1{position:relative;display:flex;align-items:center;width:100%;padding:calc(var(--purpur-spacing-100) + var(--purpur-spacing-25)) var(--purpur-spacing-200);border:0;border-radius:var(--purpur-border-radius-sm) var(--purpur-border-radius-sm) 0 0;background:transparent;font-family:var(--purpur-typography-family-default);font-weight:var(--purpur-typography-weight-normal);font-size:var(--purpur-typography-scale-100);line-height:var(--purpur-typography-line-height-loose);font-weight:500;white-space:nowrap;cursor:pointer;transition:all var(--purpur-motion-duration-150) var(--purpur-motion-easing-ease-in-out)}._purpur-tab-header_1thzh_1[aria-selected=true]{cursor:auto}._purpur-tab-header_1thzh_1:focus-visible{outline:0}._purpur-tab-header_1thzh_1:focus-visible:after{content:"";position:absolute;top:0;right:0;bottom:0;left:0;z-index:20;outline:var(--purpur-border-width-sm) solid var(--purpur-color-border-interactive-focus);outline-offset:calc(-1 * var(--purpur-border-width-sm));border-radius:var(--purpur-border-radius-sm) var(--purpur-border-radius-sm) 0 0;pointer-events:none}._purpur-tab-header--contained_1thzh_35:focus-visible:after,._purpur-tab-header--contained-negative_1thzh_35:focus-visible:after{top:calc(-1 * var(--purpur-border-width-sm))}._purpur-tab-header--line_1thzh_38{color:var(--purpur-color-text-interactive-primary);background:var(--purpur-color-functional-transparent)}._purpur-tab-header--line_1thzh_38:not(._purpur-tab-header_1thzh_1[aria-selected=true]):hover{color:var(--purpur-color-text-interactive-primary-hover);background:var(--purpur-color-background-interactive-transparent-hover)}._purpur-tab-header--line_1thzh_38:not(._purpur-tab-header_1thzh_1[aria-selected=true]):active{color:var(--purpur-color-text-interactive-primary-active);background:var(--purpur-color-background-interactive-transparent-active)}._purpur-tab-header--line-negative_1thzh_50{color:var(--purpur-color-text-interactive-primary-negative);background:var(--purpur-color-functional-transparent)}._purpur-tab-header--line-negative_1thzh_50:not(._purpur-tab-header_1thzh_1[aria-selected=true]):hover{color:var(--purpur-color-text-interactive-primary-negative-hover);background:var(--purpur-color-background-interactive-transparent-negative-hover)}._purpur-tab-header--line-negative_1thzh_50:not(._purpur-tab-header_1thzh_1[aria-selected=true]):active{color:var(--purpur-color-text-interactive-primary-negative-active);background:var(--purpur-color-background-interactive-transparent-negative-active)}._purpur-tab-header--contained_1thzh_35{padding-top:calc(var(--purpur-spacing-100) + var(--purpur-spacing-25) - var(--purpur-border-width-sm));border-top:var(--purpur-border-width-sm) solid transparent;color:var(--purpur-color-text-interactive-primary);background:var(--purpur-color-background-interactive-inactive)}._purpur-tab-header--contained_1thzh_35._purpur-tab-header_1thzh_1[aria-selected=true]{border-color:var(--purpur-color-border-interactive-primary);background:var(--purpur-color-background-primary)}._purpur-tab-header--contained_1thzh_35:not(._purpur-tab-header_1thzh_1[aria-selected=true]):hover{color:var(--purpur-color-text-interactive-primary-hover);background:var(--purpur-color-background-interactive-transparent-hover)}._purpur-tab-header--contained_1thzh_35:not(._purpur-tab-header_1thzh_1[aria-selected=true]):active{color:var(--purpur-color-text-interactive-primary-active);background:var(--purpur-color-background-interactive-transparent-active)}._purpur-tab-header--contained-negative_1thzh_35{padding-top:calc(var(--purpur-spacing-100) + var(--purpur-spacing-25) - var(--purpur-border-width-sm));border-top:var(--purpur-border-width-sm) solid transparent;color:var(--purpur-color-text-interactive-primary-negative);background:var(--purpur-color-background-interactive-inactive-negative)}._purpur-tab-header--contained-negative_1thzh_35._purpur-tab-header_1thzh_1[aria-selected=true]{border-color:var(--purpur-color-border-interactive-primary-negative);color:var(--purpur-color-text-interactive-primary);background:var(--purpur-color-background-primary)}._purpur-tab-header--contained-negative_1thzh_35:not(._purpur-tab-header_1thzh_1[aria-selected=true]):hover{color:var(--purpur-color-text-interactive-primary-negative-hover);background:var(--purpur-color-background-interactive-transparent-negative-hover)}._purpur-tab-header--contained-negative_1thzh_35:not(._purpur-tab-header_1thzh_1[aria-selected=true]):active{color:var(--purpur-color-text-interactive-primary-negative-active);background:var(--purpur-color-background-interactive-transparent-negative-active)}._purpur-tabs__wrapper_j1jjc_1{position:relative;-ms-overflow-style:none;scrollbar-width:none}._purpur-tabs__wrapper_j1jjc_1 ::-webkit-scrollbar{display:none}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9{display:none;align-items:center;position:absolute;top:0;z-index:10;height:100%;padding:0;border:var(--purpur-border-width-xs) solid var(--purpur-color-border-interactive-subtle);border-radius:var(--purpur-border-radius-xs);color:var(--purpur-color-text-default);background:var(--purpur-color-background-primary);box-shadow:var(--purpur-shadow-md);cursor:pointer}@media (prefers-reduced-motion: no-preference){._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9{transition:all var(--purpur-motion-duration-150) var(--purpur-motion-easing-ease-in-out)}}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9:after{content:"";position:absolute;inset:calc(-1 * var(--purpur-border-width-xs));border:var(--purpur-border-width-sm) solid var(--purpur-color-border-interactive-subtle-hover);border-radius:var(--purpur-border-radius-xs);box-sizing:border-box;opacity:0}@media (prefers-reduced-motion: no-preference){._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9:after{transition:all var(--purpur-motion-duration-150) var(--purpur-motion-easing-ease-in-out)}}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9:hover{box-shadow:none;border-color:transparent;color:var(--purpur-color-text-interactive-primary-hover)}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9:hover:after{opacity:1}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9:active:after{border-width:var(--purpur-border-width-xs)}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9:focus{outline:0}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9:focus-visible{outline:0;border-color:var(--purpur-color-border-interactive-subtle);box-shadow:none}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9:focus-visible:after{left:calc(-1 * var(--purpur-border-width-sm) * 2);top:calc(-1 * var(--purpur-border-width-sm) * 2);width:calc(100% + var(--purpur-border-width-sm) * 4);height:calc(100% + var(--purpur-border-width-sm) * 4);border-color:var(--purpur-color-border-interactive-focus);opacity:1;pointer-events:none}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button--left_j1jjc_71{left:0}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button--right_j1jjc_74{right:0}._purpur-tabs__wrapper--scroll-end_j1jjc_77 ._purpur-tabs__scroll-button--left_j1jjc_71,._purpur-tabs__wrapper--scroll-start_j1jjc_80 ._purpur-tabs__scroll-button--right_j1jjc_74{display:flex}._purpur-tabs--line_j1jjc_83 ._purpur-tabs__wrapper_j1jjc_1:after,._purpur-tabs--line-negative_j1jjc_83 ._purpur-tabs__wrapper_j1jjc_1:after{content:"";position:absolute;bottom:0;left:0;width:100%;height:var(--purpur-border-width-sm)}._purpur-tabs--line_j1jjc_83 ._purpur-tabs__selected-border_j1jjc_91,._purpur-tabs--line-negative_j1jjc_83 ._purpur-tabs__selected-border_j1jjc_91{position:absolute;bottom:0;left:0;z-index:10;height:var(--purpur-border-width-sm)}@media (prefers-reduced-motion: no-preference){._purpur-tabs--line_j1jjc_83 ._purpur-tabs__selected-border_j1jjc_91,._purpur-tabs--line-negative_j1jjc_83 ._purpur-tabs__selected-border_j1jjc_91{transition:all var(--purpur-motion-duration-150) var(--purpur-motion-easing-ease-in-out)}}._purpur-tabs--line_j1jjc_83 ._purpur-tabs__wrapper_j1jjc_1:after{background:var(--purpur-color-border-weak)}._purpur-tabs--line_j1jjc_83 ._purpur-tabs__selected-border_j1jjc_91{background:var(--purpur-color-border-interactive-primary)}._purpur-tabs--line-negative_j1jjc_83 ._purpur-tabs__wrapper_j1jjc_1:after{background:var(--purpur-color-border-weak-negative)}._purpur-tabs--line-negative_j1jjc_83 ._purpur-tabs__selected-border_j1jjc_91{background:var(--purpur-color-border-interactive-primary-negative)}._purpur-tabs__content-wrapper_j1jjc_115{overflow:hidden}@media (prefers-reduced-motion: no-preference){._purpur-tabs__content-wrapper_j1jjc_115{transition:height var(--purpur-motion-duration-200) var(--purpur-motion-easing-ease-in-out)}}._purpur-tabs--contained_j1jjc_123 ._purpur-tabs__list_j1jjc_123,._purpur-tabs--contained-negative_j1jjc_123 ._purpur-tabs__list_j1jjc_123{gap:var(--purpur-spacing-100)}._purpur-tabs--contained_j1jjc_123 ._purpur-tabs__content-container_j1jjc_126,._purpur-tabs--contained-negative_j1jjc_123 ._purpur-tabs__content-container_j1jjc_126{background:var(--purpur-color-background-primary)}._purpur-tabs__list_j1jjc_123{position:relative;display:inline-flex;align-items:flex-end;max-width:100%;overflow:auto}._purpur-tabs--fullWidth_j1jjc_136 ._purpur-tabs__list_j1jjc_123{min-width:100%}
1
+ ._purpur-tab-content_1ugbi_1{position:relative}._purpur-tab-content_1ugbi_1:focus-visible{outline:0}._purpur-tab-content_1ugbi_1:focus-visible:before{content:"";position:absolute;top:0;right:0;bottom:0;left:0;outline:var(--purpur-border-width-sm) solid var(--purpur-color-border-interactive-focus);border-radius:var(--purpur-border-radius-xs);pointer-events:none}._purpur-tab-content--force-mount_1ugbi_15[data-state=inactive]{display:none}._purpur-tab-header_ebsfx_1{position:relative;display:flex;align-items:center;justify-content:center;width:100%;padding:calc(var(--purpur-spacing-100) + var(--purpur-spacing-25)) var(--purpur-spacing-200);border:0;border-radius:var(--purpur-border-radius-sm) var(--purpur-border-radius-sm) 0 0;background:transparent;font-family:var(--purpur-typography-family-default);font-weight:var(--purpur-typography-weight-normal);font-size:var(--purpur-typography-scale-100);line-height:var(--purpur-typography-line-height-loose);font-weight:500;white-space:nowrap;cursor:pointer;transition:all var(--purpur-motion-duration-150) var(--purpur-motion-easing-ease-in-out)}._purpur-tab-header_ebsfx_1[aria-selected=true]{cursor:auto}._purpur-tab-header_ebsfx_1:focus-visible{outline:0}._purpur-tab-header_ebsfx_1:focus-visible:after{content:"";position:absolute;top:0;right:0;bottom:0;left:0;z-index:20;outline:var(--purpur-border-width-sm) solid var(--purpur-color-border-interactive-focus);outline-offset:calc(-1 * var(--purpur-border-width-sm));border-radius:var(--purpur-border-radius-sm) var(--purpur-border-radius-sm) 0 0;pointer-events:none}._purpur-tab-header--contained_ebsfx_36:focus-visible:after,._purpur-tab-header--contained-negative_ebsfx_36:focus-visible:after{top:calc(-1 * var(--purpur-border-width-sm))}._purpur-tab-header--line_ebsfx_39{color:var(--purpur-color-text-interactive-primary);background:var(--purpur-color-functional-transparent)}._purpur-tab-header--line_ebsfx_39:not(._purpur-tab-header_ebsfx_1[aria-selected=true]):hover{color:var(--purpur-color-text-interactive-primary-hover);background:var(--purpur-color-background-interactive-transparent-hover)}._purpur-tab-header--line_ebsfx_39:not(._purpur-tab-header_ebsfx_1[aria-selected=true]):active{color:var(--purpur-color-text-interactive-primary-active);background:var(--purpur-color-background-interactive-transparent-active)}._purpur-tab-header--line-negative_ebsfx_51{color:var(--purpur-color-text-interactive-primary-negative);background:var(--purpur-color-functional-transparent)}._purpur-tab-header--line-negative_ebsfx_51:not(._purpur-tab-header_ebsfx_1[aria-selected=true]):hover{color:var(--purpur-color-text-interactive-primary-negative-hover);background:var(--purpur-color-background-interactive-transparent-negative-hover)}._purpur-tab-header--line-negative_ebsfx_51:not(._purpur-tab-header_ebsfx_1[aria-selected=true]):active{color:var(--purpur-color-text-interactive-primary-negative-active);background:var(--purpur-color-background-interactive-transparent-negative-active)}._purpur-tab-header--contained_ebsfx_36{padding-top:calc(var(--purpur-spacing-100) + var(--purpur-spacing-25) - var(--purpur-border-width-sm));border-top:var(--purpur-border-width-sm) solid transparent;color:var(--purpur-color-text-interactive-primary);background:var(--purpur-color-background-interactive-inactive)}._purpur-tab-header--contained_ebsfx_36._purpur-tab-header_ebsfx_1[aria-selected=true]{border-color:var(--purpur-color-border-interactive-primary);background:var(--purpur-color-background-primary)}._purpur-tab-header--contained_ebsfx_36:not(._purpur-tab-header_ebsfx_1[aria-selected=true]):hover{color:var(--purpur-color-text-interactive-primary-hover);background:var(--purpur-color-background-interactive-transparent-hover)}._purpur-tab-header--contained_ebsfx_36:not(._purpur-tab-header_ebsfx_1[aria-selected=true]):active{color:var(--purpur-color-text-interactive-primary-active);background:var(--purpur-color-background-interactive-transparent-active)}._purpur-tab-header--contained-negative_ebsfx_36{padding-top:calc(var(--purpur-spacing-100) + var(--purpur-spacing-25) - var(--purpur-border-width-sm));border-top:var(--purpur-border-width-sm) solid transparent;color:var(--purpur-color-text-interactive-primary-negative);background:var(--purpur-color-background-interactive-inactive-negative)}._purpur-tab-header--contained-negative_ebsfx_36._purpur-tab-header_ebsfx_1[aria-selected=true]{border-color:var(--purpur-color-border-interactive-primary-negative);color:var(--purpur-color-text-interactive-primary);background:var(--purpur-color-background-primary)}._purpur-tab-header--contained-negative_ebsfx_36:not(._purpur-tab-header_ebsfx_1[aria-selected=true]):hover{color:var(--purpur-color-text-interactive-primary-negative-hover);background:var(--purpur-color-background-interactive-transparent-negative-hover)}._purpur-tab-header--contained-negative_ebsfx_36:not(._purpur-tab-header_ebsfx_1[aria-selected=true]):active{color:var(--purpur-color-text-interactive-primary-negative-active);background:var(--purpur-color-background-interactive-transparent-negative-active)}._purpur-tabs__wrapper_j1jjc_1{position:relative;-ms-overflow-style:none;scrollbar-width:none}._purpur-tabs__wrapper_j1jjc_1 ::-webkit-scrollbar{display:none}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9{display:none;align-items:center;position:absolute;top:0;z-index:10;height:100%;padding:0;border:var(--purpur-border-width-xs) solid var(--purpur-color-border-interactive-subtle);border-radius:var(--purpur-border-radius-xs);color:var(--purpur-color-text-default);background:var(--purpur-color-background-primary);box-shadow:var(--purpur-shadow-md);cursor:pointer}@media (prefers-reduced-motion: no-preference){._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9{transition:all var(--purpur-motion-duration-150) var(--purpur-motion-easing-ease-in-out)}}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9:after{content:"";position:absolute;inset:calc(-1 * var(--purpur-border-width-xs));border:var(--purpur-border-width-sm) solid var(--purpur-color-border-interactive-subtle-hover);border-radius:var(--purpur-border-radius-xs);box-sizing:border-box;opacity:0}@media (prefers-reduced-motion: no-preference){._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9:after{transition:all var(--purpur-motion-duration-150) var(--purpur-motion-easing-ease-in-out)}}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9:hover{box-shadow:none;border-color:transparent;color:var(--purpur-color-text-interactive-primary-hover)}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9:hover:after{opacity:1}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9:active:after{border-width:var(--purpur-border-width-xs)}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9:focus{outline:0}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9:focus-visible{outline:0;border-color:var(--purpur-color-border-interactive-subtle);box-shadow:none}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button_j1jjc_9:focus-visible:after{left:calc(-1 * var(--purpur-border-width-sm) * 2);top:calc(-1 * var(--purpur-border-width-sm) * 2);width:calc(100% + var(--purpur-border-width-sm) * 4);height:calc(100% + var(--purpur-border-width-sm) * 4);border-color:var(--purpur-color-border-interactive-focus);opacity:1;pointer-events:none}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button--left_j1jjc_71{left:0}._purpur-tabs__wrapper_j1jjc_1 ._purpur-tabs__scroll-button--right_j1jjc_74{right:0}._purpur-tabs__wrapper--scroll-end_j1jjc_77 ._purpur-tabs__scroll-button--left_j1jjc_71,._purpur-tabs__wrapper--scroll-start_j1jjc_80 ._purpur-tabs__scroll-button--right_j1jjc_74{display:flex}._purpur-tabs--line_j1jjc_83 ._purpur-tabs__wrapper_j1jjc_1:after,._purpur-tabs--line-negative_j1jjc_83 ._purpur-tabs__wrapper_j1jjc_1:after{content:"";position:absolute;bottom:0;left:0;width:100%;height:var(--purpur-border-width-sm)}._purpur-tabs--line_j1jjc_83 ._purpur-tabs__selected-border_j1jjc_91,._purpur-tabs--line-negative_j1jjc_83 ._purpur-tabs__selected-border_j1jjc_91{position:absolute;bottom:0;left:0;z-index:10;height:var(--purpur-border-width-sm)}@media (prefers-reduced-motion: no-preference){._purpur-tabs--line_j1jjc_83 ._purpur-tabs__selected-border_j1jjc_91,._purpur-tabs--line-negative_j1jjc_83 ._purpur-tabs__selected-border_j1jjc_91{transition:all var(--purpur-motion-duration-150) var(--purpur-motion-easing-ease-in-out)}}._purpur-tabs--line_j1jjc_83 ._purpur-tabs__wrapper_j1jjc_1:after{background:var(--purpur-color-border-weak)}._purpur-tabs--line_j1jjc_83 ._purpur-tabs__selected-border_j1jjc_91{background:var(--purpur-color-border-interactive-primary)}._purpur-tabs--line-negative_j1jjc_83 ._purpur-tabs__wrapper_j1jjc_1:after{background:var(--purpur-color-border-weak-negative)}._purpur-tabs--line-negative_j1jjc_83 ._purpur-tabs__selected-border_j1jjc_91{background:var(--purpur-color-border-interactive-primary-negative)}._purpur-tabs__content-wrapper_j1jjc_115{overflow:hidden}@media (prefers-reduced-motion: no-preference){._purpur-tabs__content-wrapper_j1jjc_115{transition:height var(--purpur-motion-duration-200) var(--purpur-motion-easing-ease-in-out)}}._purpur-tabs--contained_j1jjc_123 ._purpur-tabs__list_j1jjc_123,._purpur-tabs--contained-negative_j1jjc_123 ._purpur-tabs__list_j1jjc_123{gap:var(--purpur-spacing-100)}._purpur-tabs--contained_j1jjc_123 ._purpur-tabs__content-container_j1jjc_126,._purpur-tabs--contained-negative_j1jjc_123 ._purpur-tabs__content-container_j1jjc_126{background:var(--purpur-color-background-primary)}._purpur-tabs__list_j1jjc_123{position:relative;display:inline-flex;align-items:flex-end;max-width:100%;overflow:auto}._purpur-tabs--fullWidth_j1jjc_136 ._purpur-tabs__list_j1jjc_123{min-width:100%}
package/dist/tabs.cjs.js CHANGED
@@ -1,10 +1,10 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("react/jsx-runtime"),b=require("react");require("react-dom");function We(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const o=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,o.get?o:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const a=We(b);function ke(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var ae={exports:{}};/*!
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("react/jsx-runtime"),v=require("react");require("react-dom");function We(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const o=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,o.get?o:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const a=We(v);function ke(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var ae={exports:{}};/*!
2
2
  Copyright (c) 2018 Jed Watson.
3
3
  Licensed under the MIT License (MIT), see
4
4
  http://jedwatson.github.io/classnames
5
- */var ue;function qe(){return ue||(ue=1,function(e){(function(){var t={}.hasOwnProperty;function n(){for(var r="",c=0;c<arguments.length;c++){var i=arguments[c];i&&(r=s(r,o.call(this,i)))}return r}function o(r){if(typeof r=="string"||typeof r=="number")return this&&this[r]||r;if(typeof r!="object")return"";if(Array.isArray(r))return n.apply(this,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var c="";for(var i in r)t.call(r,i)&&r[i]&&(c=s(c,this&&this[i]||i));return c}function s(r,c){return c?r?r+" "+c:r+c:r}e.exports?(n.default=n,e.exports=n):window.classNames=n})()}(ae)),ae.exports}var ze=qe();const Ke=ke(ze),Ye={"purpur-icon":"_purpur-icon_8u1lq_1","purpur-icon--xxs":"_purpur-icon--xxs_8u1lq_4","purpur-icon--xs":"_purpur-icon--xs_8u1lq_8","purpur-icon--sm":"_purpur-icon--sm_8u1lq_12","purpur-icon--md":"_purpur-icon--md_8u1lq_16","purpur-icon--lg":"_purpur-icon--lg_8u1lq_20","purpur-icon--xl":"_purpur-icon--xl_8u1lq_24"},Ze=Ke.bind(Ye),le="purpur-icon",He="md",Xe=e=>e.filter(t=>Object.keys(t).length>=1).map(t=>`${t.name}="${t.value}"`).join(" "),Je=({content:e="",title:t}={})=>{const n=[{name:"xmlns",value:"http://www.w3.org/2000/svg"},{name:"fill",value:"currentColor"},{name:"viewBox",value:"0 0 24 24"},t?{name:"role",value:"img"}:{name:"aria-hidden",value:"true"}],o=t?`<title>${t}</title>`:"";return`<svg ${Xe(n)}>${o}${e}</svg>`},Qe=e=>e.replace(/<(\/?)svg([^>]*)>/g,"").trim(),_e=({["data-testid"]:e,svg:t,allyTitle:n,className:o,size:s=He,...r})=>{const c=Je({content:Qe(t.svg),title:n}),i=Ze(o,le,`${le}--${s}`);return d.jsx("span",{className:i,"data-testid":e,dangerouslySetInnerHTML:{__html:c},...r})};_e.displayName="Icon";const et={name:"chevron-left",svg:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path fill-rule="evenodd" d="M16.175 3.905a.9.9 0 0 1-.08 1.27L8.36 12l7.736 6.825a.9.9 0 0 1-1.191 1.35l-8.5-7.5a.9.9 0 0 1 0-1.35l8.5-7.5a.9.9 0 0 1 1.27.08Z" clip-rule="evenodd"/></svg>',keywords:["chevron-left"],category:"utility"},tt={name:"chevron-right",svg:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path fill-rule="evenodd" d="M7.809 3.924a.9.9 0 0 0 .115 1.267L16.094 12l-8.17 6.809a.9.9 0 0 0 1.152 1.382l9-7.5a.9.9 0 0 0 0-1.382l-9-7.5a.9.9 0 0 0-1.267.115Z" clip-rule="evenodd"/></svg>',keywords:["chevron-right"],category:"utility"};function A(e,t,{checkForDefaultPrevented:n=!0}={}){return function(s){if(e==null||e(s),n===!1||!s.defaultPrevented)return t==null?void 0:t(s)}}function ee(e,t=[]){let n=[];function o(r,c){const i=a.createContext(c),l=n.length;n=[...n,c];const u=f=>{var C;const{scope:v,children:g,...p}=f,h=((C=v==null?void 0:v[e])==null?void 0:C[l])||i,y=a.useMemo(()=>p,Object.values(p));return d.jsx(h.Provider,{value:y,children:g})};u.displayName=r+"Provider";function _(f,v){var h;const g=((h=v==null?void 0:v[e])==null?void 0:h[l])||i,p=a.useContext(g);if(p)return p;if(c!==void 0)return c;throw new Error(`\`${f}\` must be used within \`${r}\``)}return[u,_]}const s=()=>{const r=n.map(c=>a.createContext(c));return function(i){const l=(i==null?void 0:i[e])||r;return a.useMemo(()=>({[`__scope${e}`]:{...i,[e]:l}}),[i,l])}};return s.scopeName=e,[o,nt(s,...t)]}function nt(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const o=e.map(s=>({useScope:s(),scopeName:s.scopeName}));return function(r){const c=o.reduce((i,{useScope:l,scopeName:u})=>{const f=l(r)[`__scope${u}`];return{...i,...f}},{});return a.useMemo(()=>({[`__scope${t.scopeName}`]:c}),[c])}};return n.scopeName=t.scopeName,n}function de(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function ve(...e){return t=>{let n=!1;const o=e.map(s=>{const r=de(s,t);return!n&&typeof r=="function"&&(n=!0),r});if(n)return()=>{for(let s=0;s<o.length;s++){const r=o[s];typeof r=="function"?r():de(e[s],null)}}}}function q(...e){return a.useCallback(ve(...e),e)}var z=a.forwardRef((e,t)=>{const{children:n,...o}=e,s=a.Children.toArray(n),r=s.find(ot);if(r){const c=r.props.children,i=s.map(l=>l===r?a.Children.count(c)>1?a.Children.only(null):a.isValidElement(c)?c.props.children:null:l);return d.jsx(X,{...o,ref:t,children:a.isValidElement(c)?a.cloneElement(c,void 0,i):null})}return d.jsx(X,{...o,ref:t,children:n})});z.displayName="Slot";var X=a.forwardRef((e,t)=>{const{children:n,...o}=e;if(a.isValidElement(n)){const s=ct(n),r=st(o,n.props);return n.type!==a.Fragment&&(r.ref=t?ve(t,s):s),a.cloneElement(n,r)}return a.Children.count(n)>1?a.Children.only(null):null});X.displayName="SlotClone";var rt=({children:e})=>d.jsx(d.Fragment,{children:e});function ot(e){return a.isValidElement(e)&&e.type===rt}function st(e,t){const n={...t};for(const o in t){const s=e[o],r=t[o];/^on[A-Z]/.test(o)?s&&r?n[o]=(...i)=>{r(...i),s(...i)}:s&&(n[o]=s):o==="style"?n[o]={...s,...r}:o==="className"&&(n[o]=[s,r].filter(Boolean).join(" "))}return{...e,...n}}function ct(e){var o,s;let t=(o=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(s=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:s.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function it(e){const t=e+"CollectionProvider",[n,o]=ee(t),[s,r]=n(t,{collectionRef:{current:null},itemMap:new Map}),c=g=>{const{scope:p,children:h}=g,y=b.useRef(null),C=b.useRef(new Map).current;return d.jsx(s,{scope:p,itemMap:C,collectionRef:y,children:h})};c.displayName=t;const i=e+"CollectionSlot",l=b.forwardRef((g,p)=>{const{scope:h,children:y}=g,C=r(i,h),w=q(p,C.collectionRef);return d.jsx(z,{ref:w,children:y})});l.displayName=i;const u=e+"CollectionItemSlot",_="data-radix-collection-item",f=b.forwardRef((g,p)=>{const{scope:h,children:y,...C}=g,w=b.useRef(null),O=q(p,w),x=r(u,h);return b.useEffect(()=>(x.itemMap.set(w,{ref:w,...C}),()=>void x.itemMap.delete(w))),d.jsx(z,{[_]:"",ref:O,children:y})});f.displayName=u;function v(g){const p=r(e+"CollectionConsumer",g);return b.useCallback(()=>{const y=p.collectionRef.current;if(!y)return[];const C=Array.from(y.querySelectorAll(`[${_}]`));return Array.from(p.itemMap.values()).sort((x,I)=>C.indexOf(x.ref.current)-C.indexOf(I.ref.current))},[p.collectionRef,p.itemMap])}return[{Provider:c,Slot:l,ItemSlot:f},v,o]}var J=globalThis!=null&&globalThis.document?a.useLayoutEffect:()=>{},at=a.useId||(()=>{}),ut=0;function be(e){const[t,n]=a.useState(at());return J(()=>{n(o=>o??String(ut++))},[e]),t?`radix-${t}`:""}var lt=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],$=lt.reduce((e,t)=>{const n=a.forwardRef((o,s)=>{const{asChild:r,...c}=o,i=r?z:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),d.jsx(i,{...c,ref:s})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function te(e){const t=a.useRef(e);return a.useEffect(()=>{t.current=e}),a.useMemo(()=>(...n)=>{var o;return(o=t.current)==null?void 0:o.call(t,...n)},[])}function ge({prop:e,defaultProp:t,onChange:n=()=>{}}){const[o,s]=dt({defaultProp:t,onChange:n}),r=e!==void 0,c=r?e:o,i=te(n),l=a.useCallback(u=>{if(r){const f=typeof u=="function"?u(e):u;f!==e&&i(f)}else s(u)},[r,e,s,i]);return[c,l]}function dt({defaultProp:e,onChange:t}){const n=a.useState(e),[o]=n,s=a.useRef(o),r=te(t);return a.useEffect(()=>{s.current!==o&&(r(o),s.current=o)},[o,s,r]),n}var ft=a.createContext(void 0);function he(e){const t=a.useContext(ft);return e||t||"ltr"}var Z="rovingFocusGroup.onEntryFocus",pt={bubbles:!1,cancelable:!0},K="RovingFocusGroup",[Q,Ce,mt]=it(K),[_t,we]=ee(K,[mt]),[vt,bt]=_t(K),xe=a.forwardRef((e,t)=>d.jsx(Q.Provider,{scope:e.__scopeRovingFocusGroup,children:d.jsx(Q.Slot,{scope:e.__scopeRovingFocusGroup,children:d.jsx(gt,{...e,ref:t})})}));xe.displayName=K;var gt=a.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:o,loop:s=!1,dir:r,currentTabStopId:c,defaultCurrentTabStopId:i,onCurrentTabStopIdChange:l,onEntryFocus:u,preventScrollOnEntryFocus:_=!1,...f}=e,v=a.useRef(null),g=q(t,v),p=he(r),[h=null,y]=ge({prop:c,defaultProp:i,onChange:l}),[C,w]=a.useState(!1),O=te(u),x=Ce(n),I=a.useRef(!1),[D,B]=a.useState(0);return a.useEffect(()=>{const S=v.current;if(S)return S.addEventListener(Z,O),()=>S.removeEventListener(Z,O)},[O]),d.jsx(vt,{scope:n,orientation:o,dir:p,loop:s,currentTabStopId:h,onItemFocus:a.useCallback(S=>y(S),[y]),onItemShiftTab:a.useCallback(()=>w(!0),[]),onFocusableItemAdd:a.useCallback(()=>B(S=>S+1),[]),onFocusableItemRemove:a.useCallback(()=>B(S=>S-1),[]),children:d.jsx($.div,{tabIndex:C||D===0?-1:0,"data-orientation":o,...f,ref:g,style:{outline:"none",...e.style},onMouseDown:A(e.onMouseDown,()=>{I.current=!0}),onFocus:A(e.onFocus,S=>{const Y=!I.current;if(S.target===S.currentTarget&&Y&&!C){const F=new CustomEvent(Z,pt);if(S.currentTarget.dispatchEvent(F),!F.defaultPrevented){const L=x().filter(T=>T.focusable),V=L.find(T=>T.active),U=L.find(T=>T.id===h),W=[V,U,...L].filter(Boolean).map(T=>T.ref.current);je(W,_)}}I.current=!1}),onBlur:A(e.onBlur,()=>w(!1))})})}),ye="RovingFocusGroupItem",Se=a.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:o=!0,active:s=!1,tabStopId:r,...c}=e,i=be(),l=r||i,u=bt(ye,n),_=u.currentTabStopId===l,f=Ce(n),{onFocusableItemAdd:v,onFocusableItemRemove:g}=u;return a.useEffect(()=>{if(o)return v(),()=>g()},[o,v,g]),d.jsx(Q.ItemSlot,{scope:n,id:l,focusable:o,active:s,children:d.jsx($.span,{tabIndex:_?0:-1,"data-orientation":u.orientation,...c,ref:t,onMouseDown:A(e.onMouseDown,p=>{o?u.onItemFocus(l):p.preventDefault()}),onFocus:A(e.onFocus,()=>u.onItemFocus(l)),onKeyDown:A(e.onKeyDown,p=>{if(p.key==="Tab"&&p.shiftKey){u.onItemShiftTab();return}if(p.target!==p.currentTarget)return;const h=wt(p,u.orientation,u.dir);if(h!==void 0){if(p.metaKey||p.ctrlKey||p.altKey||p.shiftKey)return;p.preventDefault();let C=f().filter(w=>w.focusable).map(w=>w.ref.current);if(h==="last")C.reverse();else if(h==="prev"||h==="next"){h==="prev"&&C.reverse();const w=C.indexOf(p.currentTarget);C=u.loop?xt(C,w+1):C.slice(w+1)}setTimeout(()=>je(C))}})})})});Se.displayName=ye;var ht={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function Ct(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function wt(e,t,n){const o=Ct(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(o))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(o)))return ht[o]}function je(e,t=!1){const n=document.activeElement;for(const o of e)if(o===n||(o.focus({preventScroll:t}),document.activeElement!==n))return}function xt(e,t){return e.map((n,o)=>e[(t+o)%e.length])}var yt=xe,St=Se;function jt(e,t){return a.useReducer((n,o)=>t[n][o]??n,e)}var Ie=e=>{const{present:t,children:n}=e,o=It(t),s=typeof n=="function"?n({present:o.isPresent}):a.Children.only(n),r=q(o.ref,Rt(s));return typeof n=="function"||o.isPresent?a.cloneElement(s,{ref:r}):null};Ie.displayName="Presence";function It(e){const[t,n]=a.useState(),o=a.useRef({}),s=a.useRef(e),r=a.useRef("none"),c=e?"mounted":"unmounted",[i,l]=jt(c,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return a.useEffect(()=>{const u=k(o.current);r.current=i==="mounted"?u:"none"},[i]),J(()=>{const u=o.current,_=s.current;if(_!==e){const v=r.current,g=k(u);e?l("MOUNT"):g==="none"||(u==null?void 0:u.display)==="none"?l("UNMOUNT"):l(_&&v!==g?"ANIMATION_OUT":"UNMOUNT"),s.current=e}},[e,l]),J(()=>{if(t){let u;const _=t.ownerDocument.defaultView??window,f=g=>{const h=k(o.current).includes(g.animationName);if(g.target===t&&h&&(l("ANIMATION_END"),!s.current)){const y=t.style.animationFillMode;t.style.animationFillMode="forwards",u=_.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=y)})}},v=g=>{g.target===t&&(r.current=k(o.current))};return t.addEventListener("animationstart",v),t.addEventListener("animationcancel",f),t.addEventListener("animationend",f),()=>{_.clearTimeout(u),t.removeEventListener("animationstart",v),t.removeEventListener("animationcancel",f),t.removeEventListener("animationend",f)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(i),ref:a.useCallback(u=>{u&&(o.current=getComputedStyle(u)),n(u)},[])}}function k(e){return(e==null?void 0:e.animationName)||"none"}function Rt(e){var o,s;let t=(o=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(s=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:s.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var ne="Tabs",[Nt,Kt]=ee(ne,[we]),Re=we(),[Tt,re]=Nt(ne),Ne=a.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,onValueChange:s,defaultValue:r,orientation:c="horizontal",dir:i,activationMode:l="automatic",...u}=e,_=he(i),[f,v]=ge({prop:o,onChange:s,defaultProp:r});return d.jsx(Tt,{scope:n,baseId:be(),value:f,onValueChange:v,orientation:c,dir:_,activationMode:l,children:d.jsx($.div,{dir:_,"data-orientation":c,...u,ref:t})})});Ne.displayName=ne;var Te="TabsList",Ee=a.forwardRef((e,t)=>{const{__scopeTabs:n,loop:o=!0,...s}=e,r=re(Te,n),c=Re(n);return d.jsx(yt,{asChild:!0,...c,orientation:r.orientation,dir:r.dir,loop:o,children:d.jsx($.div,{role:"tablist","aria-orientation":r.orientation,...s,ref:t})})});Ee.displayName=Te;var Ae="TabsTrigger",Oe=a.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,disabled:s=!1,...r}=e,c=re(Ae,n),i=Re(n),l=Fe(c.baseId,o),u=$e(c.baseId,o),_=o===c.value;return d.jsx(St,{asChild:!0,...i,focusable:!s,active:_,children:d.jsx($.button,{type:"button",role:"tab","aria-selected":_,"aria-controls":u,"data-state":_?"active":"inactive","data-disabled":s?"":void 0,disabled:s,id:l,...r,ref:t,onMouseDown:A(e.onMouseDown,f=>{!s&&f.button===0&&f.ctrlKey===!1?c.onValueChange(o):f.preventDefault()}),onKeyDown:A(e.onKeyDown,f=>{[" ","Enter"].includes(f.key)&&c.onValueChange(o)}),onFocus:A(e.onFocus,()=>{const f=c.activationMode!=="manual";!_&&!s&&f&&c.onValueChange(o)})})})});Oe.displayName=Ae;var Me="TabsContent",Pe=a.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,forceMount:s,children:r,...c}=e,i=re(Me,n),l=Fe(i.baseId,o),u=$e(i.baseId,o),_=o===i.value,f=a.useRef(_);return a.useEffect(()=>{const v=requestAnimationFrame(()=>f.current=!1);return()=>cancelAnimationFrame(v)},[]),d.jsx(Ie,{present:s||_,children:({present:v})=>d.jsx($.div,{"data-state":_?"active":"inactive","data-orientation":i.orientation,role:"tabpanel","aria-labelledby":l,hidden:!v,id:u,tabIndex:0,...c,ref:t,style:{...e.style,animationDuration:f.current?"0s":void 0},children:v&&r})})});Pe.displayName=Me;function Fe(e,t){return`${e}-trigger-${t}`}function $e(e,t){return`${e}-content-${t}`}var Et=Ne,At=Ee,Ot=Oe,Mt=Pe;function Pt(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var H={exports:{}};/*!
5
+ */var ue;function qe(){return ue||(ue=1,function(e){(function(){var t={}.hasOwnProperty;function n(){for(var r="",c=0;c<arguments.length;c++){var i=arguments[c];i&&(r=s(r,o.call(this,i)))}return r}function o(r){if(typeof r=="string"||typeof r=="number")return this&&this[r]||r;if(typeof r!="object")return"";if(Array.isArray(r))return n.apply(this,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var c="";for(var i in r)t.call(r,i)&&r[i]&&(c=s(c,this&&this[i]||i));return c}function s(r,c){return c?r?r+" "+c:r+c:r}e.exports?(n.default=n,e.exports=n):window.classNames=n})()}(ae)),ae.exports}var Ke=qe();const ze=ke(Ke),Ye={"purpur-icon":"_purpur-icon_8u1lq_1","purpur-icon--xxs":"_purpur-icon--xxs_8u1lq_4","purpur-icon--xs":"_purpur-icon--xs_8u1lq_8","purpur-icon--sm":"_purpur-icon--sm_8u1lq_12","purpur-icon--md":"_purpur-icon--md_8u1lq_16","purpur-icon--lg":"_purpur-icon--lg_8u1lq_20","purpur-icon--xl":"_purpur-icon--xl_8u1lq_24"},Ze=ze.bind(Ye),le="purpur-icon",Xe="md",He=e=>e.filter(t=>Object.keys(t).length>=1).map(t=>`${t.name}="${t.value}"`).join(" "),Je=({content:e="",title:t}={})=>{const n=[{name:"xmlns",value:"http://www.w3.org/2000/svg"},{name:"fill",value:"currentColor"},{name:"viewBox",value:"0 0 24 24"},t?{name:"role",value:"img"}:{name:"aria-hidden",value:"true"}],o=t?`<title>${t}</title>`:"";return`<svg ${He(n)}>${o}${e}</svg>`},Qe=e=>e.replace(/<(\/?)svg([^>]*)>/g,"").trim(),_e=({["data-testid"]:e,svg:t,allyTitle:n,className:o,size:s=Xe,...r})=>{const c=Je({content:Qe(t.svg),title:n}),i=Ze(o,le,`${le}--${s}`);return d.jsx("span",{className:i,"data-testid":e,dangerouslySetInnerHTML:{__html:c},...r})};_e.displayName="Icon";const et={name:"chevron-left",svg:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path fill-rule="evenodd" d="M16.175 3.905a.9.9 0 0 1-.08 1.27L8.36 12l7.736 6.825a.9.9 0 0 1-1.191 1.35l-8.5-7.5a.9.9 0 0 1 0-1.35l8.5-7.5a.9.9 0 0 1 1.27.08Z" clip-rule="evenodd"/></svg>',keywords:["chevron-left"],category:"utility"},tt={name:"chevron-right",svg:'<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="currentColor"><path fill-rule="evenodd" d="M7.809 3.924a.9.9 0 0 0 .115 1.267L16.094 12l-8.17 6.809a.9.9 0 0 0 1.152 1.382l9-7.5a.9.9 0 0 0 0-1.382l-9-7.5a.9.9 0 0 0-1.267.115Z" clip-rule="evenodd"/></svg>',keywords:["chevron-right"],category:"utility"};function A(e,t,{checkForDefaultPrevented:n=!0}={}){return function(s){if(e==null||e(s),n===!1||!s.defaultPrevented)return t==null?void 0:t(s)}}function ee(e,t=[]){let n=[];function o(r,c){const i=a.createContext(c),l=n.length;n=[...n,c];const u=f=>{var x;const{scope:b,children:g,...p}=f,h=((x=b==null?void 0:b[e])==null?void 0:x[l])||i,y=a.useMemo(()=>p,Object.values(p));return d.jsx(h.Provider,{value:y,children:g})};u.displayName=r+"Provider";function _(f,b){var h;const g=((h=b==null?void 0:b[e])==null?void 0:h[l])||i,p=a.useContext(g);if(p)return p;if(c!==void 0)return c;throw new Error(`\`${f}\` must be used within \`${r}\``)}return[u,_]}const s=()=>{const r=n.map(c=>a.createContext(c));return function(i){const l=(i==null?void 0:i[e])||r;return a.useMemo(()=>({[`__scope${e}`]:{...i,[e]:l}}),[i,l])}};return s.scopeName=e,[o,nt(s,...t)]}function nt(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const o=e.map(s=>({useScope:s(),scopeName:s.scopeName}));return function(r){const c=o.reduce((i,{useScope:l,scopeName:u})=>{const f=l(r)[`__scope${u}`];return{...i,...f}},{});return a.useMemo(()=>({[`__scope${t.scopeName}`]:c}),[c])}};return n.scopeName=t.scopeName,n}function de(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function be(...e){return t=>{let n=!1;const o=e.map(s=>{const r=de(s,t);return!n&&typeof r=="function"&&(n=!0),r});if(n)return()=>{for(let s=0;s<o.length;s++){const r=o[s];typeof r=="function"?r():de(e[s],null)}}}}function q(...e){return a.useCallback(be(...e),e)}var K=a.forwardRef((e,t)=>{const{children:n,...o}=e,s=a.Children.toArray(n),r=s.find(ot);if(r){const c=r.props.children,i=s.map(l=>l===r?a.Children.count(c)>1?a.Children.only(null):a.isValidElement(c)?c.props.children:null:l);return d.jsx(H,{...o,ref:t,children:a.isValidElement(c)?a.cloneElement(c,void 0,i):null})}return d.jsx(H,{...o,ref:t,children:n})});K.displayName="Slot";var H=a.forwardRef((e,t)=>{const{children:n,...o}=e;if(a.isValidElement(n)){const s=ct(n),r=st(o,n.props);return n.type!==a.Fragment&&(r.ref=t?be(t,s):s),a.cloneElement(n,r)}return a.Children.count(n)>1?a.Children.only(null):null});H.displayName="SlotClone";var rt=({children:e})=>d.jsx(d.Fragment,{children:e});function ot(e){return a.isValidElement(e)&&e.type===rt}function st(e,t){const n={...t};for(const o in t){const s=e[o],r=t[o];/^on[A-Z]/.test(o)?s&&r?n[o]=(...i)=>{r(...i),s(...i)}:s&&(n[o]=s):o==="style"?n[o]={...s,...r}:o==="className"&&(n[o]=[s,r].filter(Boolean).join(" "))}return{...e,...n}}function ct(e){var o,s;let t=(o=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(s=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:s.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function it(e){const t=e+"CollectionProvider",[n,o]=ee(t),[s,r]=n(t,{collectionRef:{current:null},itemMap:new Map}),c=g=>{const{scope:p,children:h}=g,y=v.useRef(null),x=v.useRef(new Map).current;return d.jsx(s,{scope:p,itemMap:x,collectionRef:y,children:h})};c.displayName=t;const i=e+"CollectionSlot",l=v.forwardRef((g,p)=>{const{scope:h,children:y}=g,x=r(i,h),C=q(p,x.collectionRef);return d.jsx(K,{ref:C,children:y})});l.displayName=i;const u=e+"CollectionItemSlot",_="data-radix-collection-item",f=v.forwardRef((g,p)=>{const{scope:h,children:y,...x}=g,C=v.useRef(null),O=q(p,C),w=r(u,h);return v.useEffect(()=>(w.itemMap.set(C,{ref:C,...x}),()=>void w.itemMap.delete(C))),d.jsx(K,{[_]:"",ref:O,children:y})});f.displayName=u;function b(g){const p=r(e+"CollectionConsumer",g);return v.useCallback(()=>{const y=p.collectionRef.current;if(!y)return[];const x=Array.from(y.querySelectorAll(`[${_}]`));return Array.from(p.itemMap.values()).sort((w,I)=>x.indexOf(w.ref.current)-x.indexOf(I.ref.current))},[p.collectionRef,p.itemMap])}return[{Provider:c,Slot:l,ItemSlot:f},b,o]}var J=globalThis!=null&&globalThis.document?a.useLayoutEffect:()=>{},at=a.useId||(()=>{}),ut=0;function ve(e){const[t,n]=a.useState(at());return J(()=>{n(o=>o??String(ut++))},[e]),t?`radix-${t}`:""}var lt=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","span","svg","ul"],$=lt.reduce((e,t)=>{const n=a.forwardRef((o,s)=>{const{asChild:r,...c}=o,i=r?K:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),d.jsx(i,{...c,ref:s})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function te(e){const t=a.useRef(e);return a.useEffect(()=>{t.current=e}),a.useMemo(()=>(...n)=>{var o;return(o=t.current)==null?void 0:o.call(t,...n)},[])}function ge({prop:e,defaultProp:t,onChange:n=()=>{}}){const[o,s]=dt({defaultProp:t,onChange:n}),r=e!==void 0,c=r?e:o,i=te(n),l=a.useCallback(u=>{if(r){const f=typeof u=="function"?u(e):u;f!==e&&i(f)}else s(u)},[r,e,s,i]);return[c,l]}function dt({defaultProp:e,onChange:t}){const n=a.useState(e),[o]=n,s=a.useRef(o),r=te(t);return a.useEffect(()=>{s.current!==o&&(r(o),s.current=o)},[o,s,r]),n}var ft=a.createContext(void 0);function he(e){const t=a.useContext(ft);return e||t||"ltr"}var Z="rovingFocusGroup.onEntryFocus",pt={bubbles:!1,cancelable:!0},z="RovingFocusGroup",[Q,xe,mt]=it(z),[_t,Ce]=ee(z,[mt]),[bt,vt]=_t(z),we=a.forwardRef((e,t)=>d.jsx(Q.Provider,{scope:e.__scopeRovingFocusGroup,children:d.jsx(Q.Slot,{scope:e.__scopeRovingFocusGroup,children:d.jsx(gt,{...e,ref:t})})}));we.displayName=z;var gt=a.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:o,loop:s=!1,dir:r,currentTabStopId:c,defaultCurrentTabStopId:i,onCurrentTabStopIdChange:l,onEntryFocus:u,preventScrollOnEntryFocus:_=!1,...f}=e,b=a.useRef(null),g=q(t,b),p=he(r),[h=null,y]=ge({prop:c,defaultProp:i,onChange:l}),[x,C]=a.useState(!1),O=te(u),w=xe(n),I=a.useRef(!1),[D,B]=a.useState(0);return a.useEffect(()=>{const S=b.current;if(S)return S.addEventListener(Z,O),()=>S.removeEventListener(Z,O)},[O]),d.jsx(bt,{scope:n,orientation:o,dir:p,loop:s,currentTabStopId:h,onItemFocus:a.useCallback(S=>y(S),[y]),onItemShiftTab:a.useCallback(()=>C(!0),[]),onFocusableItemAdd:a.useCallback(()=>B(S=>S+1),[]),onFocusableItemRemove:a.useCallback(()=>B(S=>S-1),[]),children:d.jsx($.div,{tabIndex:x||D===0?-1:0,"data-orientation":o,...f,ref:g,style:{outline:"none",...e.style},onMouseDown:A(e.onMouseDown,()=>{I.current=!0}),onFocus:A(e.onFocus,S=>{const Y=!I.current;if(S.target===S.currentTarget&&Y&&!x){const F=new CustomEvent(Z,pt);if(S.currentTarget.dispatchEvent(F),!F.defaultPrevented){const L=w().filter(T=>T.focusable),V=L.find(T=>T.active),U=L.find(T=>T.id===h),W=[V,U,...L].filter(Boolean).map(T=>T.ref.current);je(W,_)}}I.current=!1}),onBlur:A(e.onBlur,()=>C(!1))})})}),ye="RovingFocusGroupItem",Se=a.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:o=!0,active:s=!1,tabStopId:r,...c}=e,i=ve(),l=r||i,u=vt(ye,n),_=u.currentTabStopId===l,f=xe(n),{onFocusableItemAdd:b,onFocusableItemRemove:g}=u;return a.useEffect(()=>{if(o)return b(),()=>g()},[o,b,g]),d.jsx(Q.ItemSlot,{scope:n,id:l,focusable:o,active:s,children:d.jsx($.span,{tabIndex:_?0:-1,"data-orientation":u.orientation,...c,ref:t,onMouseDown:A(e.onMouseDown,p=>{o?u.onItemFocus(l):p.preventDefault()}),onFocus:A(e.onFocus,()=>u.onItemFocus(l)),onKeyDown:A(e.onKeyDown,p=>{if(p.key==="Tab"&&p.shiftKey){u.onItemShiftTab();return}if(p.target!==p.currentTarget)return;const h=Ct(p,u.orientation,u.dir);if(h!==void 0){if(p.metaKey||p.ctrlKey||p.altKey||p.shiftKey)return;p.preventDefault();let x=f().filter(C=>C.focusable).map(C=>C.ref.current);if(h==="last")x.reverse();else if(h==="prev"||h==="next"){h==="prev"&&x.reverse();const C=x.indexOf(p.currentTarget);x=u.loop?wt(x,C+1):x.slice(C+1)}setTimeout(()=>je(x))}})})})});Se.displayName=ye;var ht={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function xt(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function Ct(e,t,n){const o=xt(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(o))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(o)))return ht[o]}function je(e,t=!1){const n=document.activeElement;for(const o of e)if(o===n||(o.focus({preventScroll:t}),document.activeElement!==n))return}function wt(e,t){return e.map((n,o)=>e[(t+o)%e.length])}var yt=we,St=Se;function jt(e,t){return a.useReducer((n,o)=>t[n][o]??n,e)}var Ie=e=>{const{present:t,children:n}=e,o=It(t),s=typeof n=="function"?n({present:o.isPresent}):a.Children.only(n),r=q(o.ref,Rt(s));return typeof n=="function"||o.isPresent?a.cloneElement(s,{ref:r}):null};Ie.displayName="Presence";function It(e){const[t,n]=a.useState(),o=a.useRef({}),s=a.useRef(e),r=a.useRef("none"),c=e?"mounted":"unmounted",[i,l]=jt(c,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return a.useEffect(()=>{const u=k(o.current);r.current=i==="mounted"?u:"none"},[i]),J(()=>{const u=o.current,_=s.current;if(_!==e){const b=r.current,g=k(u);e?l("MOUNT"):g==="none"||(u==null?void 0:u.display)==="none"?l("UNMOUNT"):l(_&&b!==g?"ANIMATION_OUT":"UNMOUNT"),s.current=e}},[e,l]),J(()=>{if(t){let u;const _=t.ownerDocument.defaultView??window,f=g=>{const h=k(o.current).includes(g.animationName);if(g.target===t&&h&&(l("ANIMATION_END"),!s.current)){const y=t.style.animationFillMode;t.style.animationFillMode="forwards",u=_.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=y)})}},b=g=>{g.target===t&&(r.current=k(o.current))};return t.addEventListener("animationstart",b),t.addEventListener("animationcancel",f),t.addEventListener("animationend",f),()=>{_.clearTimeout(u),t.removeEventListener("animationstart",b),t.removeEventListener("animationcancel",f),t.removeEventListener("animationend",f)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(i),ref:a.useCallback(u=>{u&&(o.current=getComputedStyle(u)),n(u)},[])}}function k(e){return(e==null?void 0:e.animationName)||"none"}function Rt(e){var o,s;let t=(o=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:o.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(s=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:s.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var ne="Tabs",[Nt,zt]=ee(ne,[Ce]),Re=Ce(),[Tt,re]=Nt(ne),Ne=a.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,onValueChange:s,defaultValue:r,orientation:c="horizontal",dir:i,activationMode:l="automatic",...u}=e,_=he(i),[f,b]=ge({prop:o,onChange:s,defaultProp:r});return d.jsx(Tt,{scope:n,baseId:ve(),value:f,onValueChange:b,orientation:c,dir:_,activationMode:l,children:d.jsx($.div,{dir:_,"data-orientation":c,...u,ref:t})})});Ne.displayName=ne;var Te="TabsList",Ee=a.forwardRef((e,t)=>{const{__scopeTabs:n,loop:o=!0,...s}=e,r=re(Te,n),c=Re(n);return d.jsx(yt,{asChild:!0,...c,orientation:r.orientation,dir:r.dir,loop:o,children:d.jsx($.div,{role:"tablist","aria-orientation":r.orientation,...s,ref:t})})});Ee.displayName=Te;var Ae="TabsTrigger",Oe=a.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,disabled:s=!1,...r}=e,c=re(Ae,n),i=Re(n),l=Fe(c.baseId,o),u=$e(c.baseId,o),_=o===c.value;return d.jsx(St,{asChild:!0,...i,focusable:!s,active:_,children:d.jsx($.button,{type:"button",role:"tab","aria-selected":_,"aria-controls":u,"data-state":_?"active":"inactive","data-disabled":s?"":void 0,disabled:s,id:l,...r,ref:t,onMouseDown:A(e.onMouseDown,f=>{!s&&f.button===0&&f.ctrlKey===!1?c.onValueChange(o):f.preventDefault()}),onKeyDown:A(e.onKeyDown,f=>{[" ","Enter"].includes(f.key)&&c.onValueChange(o)}),onFocus:A(e.onFocus,()=>{const f=c.activationMode!=="manual";!_&&!s&&f&&c.onValueChange(o)})})})});Oe.displayName=Ae;var Me="TabsContent",Pe=a.forwardRef((e,t)=>{const{__scopeTabs:n,value:o,forceMount:s,children:r,...c}=e,i=re(Me,n),l=Fe(i.baseId,o),u=$e(i.baseId,o),_=o===i.value,f=a.useRef(_);return a.useEffect(()=>{const b=requestAnimationFrame(()=>f.current=!1);return()=>cancelAnimationFrame(b)},[]),d.jsx(Ie,{present:s||_,children:({present:b})=>d.jsx($.div,{"data-state":_?"active":"inactive","data-orientation":i.orientation,role:"tabpanel","aria-labelledby":l,hidden:!b,id:u,tabIndex:0,...c,ref:t,style:{...e.style,animationDuration:f.current?"0s":void 0},children:b&&r})})});Pe.displayName=Me;function Fe(e,t){return`${e}-trigger-${t}`}function $e(e,t){return`${e}-content-${t}`}var Et=Ne,At=Ee,Ot=Oe,Mt=Pe;function Pt(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var X={exports:{}};/*!
6
6
  Copyright (c) 2018 Jed Watson.
7
7
  Licensed under the MIT License (MIT), see
8
8
  http://jedwatson.github.io/classnames
9
- */var fe;function Ft(){return fe||(fe=1,function(e){(function(){var t={}.hasOwnProperty;function n(){for(var r="",c=0;c<arguments.length;c++){var i=arguments[c];i&&(r=s(r,o.call(this,i)))}return r}function o(r){if(typeof r=="string"||typeof r=="number")return this&&this[r]||r;if(typeof r!="object")return"";if(Array.isArray(r))return n.apply(this,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var c="";for(var i in r)t.call(r,i)&&r[i]&&(c=s(c,this&&this[i]||i));return c}function s(r,c){return c?r?r+" "+c:r+c:r}e.exports?(n.default=n,e.exports=n):window.classNames=n})()}(H)),H.exports}var $t=Ft();const oe=Pt($t),Dt={"purpur-tab-content":"_purpur-tab-content_1ugbi_1","purpur-tab-content--force-mount":"_purpur-tab-content--force-mount_1ugbi_15"},Lt=oe.bind(Dt),pe="purpur-tab-content",Vt=b.forwardRef(({children:e,tabId:t,"data-testid":n,className:o,disableForceMount:s,...r},c)=>d.jsx(Mt,{ref:c,className:Lt([pe,o,{[`${pe}--force-mount`]:!s}]),"data-testid":n,value:t,forceMount:!s||void 0,...r,children:e})),Bt=e=>!!e&&b.isValidElement(e)&&!!e.props.name&&!!e.props.tabId,Ut={"purpur-tab-header":"_purpur-tab-header_1thzh_1","purpur-tab-header--contained":"_purpur-tab-header--contained_1thzh_35","purpur-tab-header--contained-negative":"_purpur-tab-header--contained-negative_1thzh_35","purpur-tab-header--line":"_purpur-tab-header--line_1thzh_38","purpur-tab-header--line-negative":"_purpur-tab-header--line-negative_1thzh_50"},Gt=oe.bind(Ut),me="purpur-tab-header",Wt=b.forwardRef(({index:e,tabId:t,variant:n,negative:o,onFocus:s,"data-testid":r,children:c},i)=>d.jsx(Ot,{id:`${t}-trigger`,className:Gt([me,`${me}--${n}${o?"-negative":""}`]),value:t,"data-testid":r,"data-index":e,ref:i,onFocus:s,children:c})),kt={"purpur-tabs__wrapper":"_purpur-tabs__wrapper_j1jjc_1","purpur-tabs__scroll-button":"_purpur-tabs__scroll-button_j1jjc_9","purpur-tabs__scroll-button--left":"_purpur-tabs__scroll-button--left_j1jjc_71","purpur-tabs__scroll-button--right":"_purpur-tabs__scroll-button--right_j1jjc_74","purpur-tabs__wrapper--scroll-end":"_purpur-tabs__wrapper--scroll-end_j1jjc_77","purpur-tabs__wrapper--scroll-start":"_purpur-tabs__wrapper--scroll-start_j1jjc_80","purpur-tabs--line":"_purpur-tabs--line_j1jjc_83","purpur-tabs--line-negative":"_purpur-tabs--line-negative_j1jjc_83","purpur-tabs__selected-border":"_purpur-tabs__selected-border_j1jjc_91","purpur-tabs__content-wrapper":"_purpur-tabs__content-wrapper_j1jjc_115","purpur-tabs--contained":"_purpur-tabs--contained_j1jjc_123","purpur-tabs__list":"_purpur-tabs__list_j1jjc_123","purpur-tabs--contained-negative":"_purpur-tabs--contained-negative_j1jjc_123","purpur-tabs__content-container":"_purpur-tabs__content-container_j1jjc_126","purpur-tabs--fullWidth":"_purpur-tabs--fullWidth_j1jjc_136"},qt=["line","contained"],De=e=>new CustomEvent("tabChangeDetail",{detail:{value:e}}),P=oe.bind(kt),R="purpur-tabs",zt=(e,t)=>{var l;if(typeof(e==null?void 0:e.getBoundingClientRect)!="function"||typeof(t==null?void 0:t.scroll)!="function")return;const n=e.getBoundingClientRect(),o=t.getBoundingClientRect(),s=t.clientWidth,r=parseInt((l=getComputedStyle(t).borderLeftWidth)==null?void 0:l.split("px")[0],10),c=o.left+(isNaN(r)?0:r);let i;n.right>o.right&&(i=n.left+t.scrollLeft,i=i+n.width-s+s*.1,i=i-c),n.left<o.left&&(i=n.left+t.scrollLeft,i=i-s*.1,i=i-c),i!==void 0&&t.scroll({left:i,behavior:"smooth"})},Le=({children:e,variant:t="line",negative:n=!1,fullWidth:o=!1,onChange:s,className:r,defaultValue:c,animateHeight:i=!1,"data-testid":l,value:u,..._})=>{const f=b.useRef(null),[v,g]=b.useState(-1),[p,h]=b.useState({}),[y,C]=b.useState(0),[w,O]=b.useState(0),x=b.Children.toArray(e).filter(Bt),I=b.useRef(null),D=b.useRef(new Array(x.length)),B=200,S=t==="line",Y=P([R,`${R}--${t}${n?"-negative":""}`,{[`${R}--fullWidth`]:o},r]),F=b.Children.map(x,({props:{tabId:m}})=>m),L=()=>{const m=F.findIndex(j=>j===c);return m>=0?m:0};b.useEffect(()=>{u&&U(x.findIndex(m=>m.props.tabId===u))},[x,u]);const[V,U]=b.useState(L);if(new Set(F).size!==F.length)throw new Error("tabId must be unique");const G=(m,j)=>j||l?`${j||l}-${m}`:void 0,W=()=>{if(!S)return;const m=D.current[V];C((m==null?void 0:m.offsetLeft)||0),O((m==null?void 0:m.getBoundingClientRect().width)||0)},T=m=>{S&&!u&&U(x.findIndex(j=>j.props.tabId===m)),s==null||s(De(m))},Ve=m=>{if(I!=null&&I.current){const{scrollLeft:j}=I.current,M=m==="left"?-200:B;I.current.scroll({left:j+M,behavior:"smooth"})}},se=({side:m})=>d.jsx("button",{className:P(`${R}__scroll-button`,`${R}__scroll-button--${m}`),onClick:()=>Ve(m),type:"button","aria-hidden":"true",tabIndex:-1,"data-testid":G("scroll-button"),children:d.jsx(_e,{svg:m==="left"?et:tt,size:"md"})});return b.useEffect(()=>{const m=()=>{if(f.current&&i){const M=f.current.offsetHeight;g(M)}},j=()=>{m(),W()};return m(),window.addEventListener("resize",j),()=>{window.removeEventListener("resize",j)}},[V,i]),b.useEffect(()=>{W()},[V,o,x.length,t]),b.useEffect(()=>{const m=E=>{if(E.every(N=>N.isIntersecting)&&E.length===x.length){h({});return}E.forEach(N=>{const ie=Number(N.target.getAttribute("data-index")),Be=ie===0,Ue=ie===x.length-1;h(Ge=>({...Ge,...Be&&{[`${R}__wrapper--scroll-end`]:!N.isIntersecting},...Ue&&{[`${R}__wrapper--scroll-start`]:!N.isIntersecting}}))})},j=new IntersectionObserver(m,{threshold:[.99],root:I.current}),M=D.current;return M.forEach(E=>j.observe(E)),()=>{M.forEach(E=>j.unobserve(E))}},[x.length]),d.jsx(Et,{defaultValue:c??x[0].props.tabId,onValueChange:T,"data-testid":l,className:Y,value:u,..._,children:d.jsxs("div",{className:P(`${R}__container`),children:[d.jsxs("div",{className:P([`${R}__wrapper`,p]),children:[d.jsxs(At,{ref:m=>{I.current=m},className:P(`${R}__list`),children:[b.Children.map(x,(m,j)=>{const{name:M,tabId:E,"data-testid":ce}=m.props;return d.jsx(Wt,{"data-testid":G("header",ce),index:j,tabId:E,ref:N=>{N&&(D.current[j]=N)},onFocus:N=>{zt(N.target,I.current)},variant:t,negative:n,children:M})}),S&&d.jsx("div",{className:P(`${R}__selected-border`),style:{width:w,transform:`translateX(${y}px)`},"data-testid":G("selected-border")})]}),d.jsx(se,{side:"left"}),d.jsx(se,{side:"right"})]}),d.jsx("div",{className:P(`${R}__content-wrapper`),style:{height:i&&v>-1?`${v}px`:"auto"},children:d.jsx("div",{ref:f,className:P(`${R}__content-container`),children:b.Children.map(x,m=>m)})})]})})};Le.Content=Vt;exports.Tabs=Le;exports.createTabChangeDetailEvent=De;exports.tabsVariants=qt;
9
+ */var fe;function Ft(){return fe||(fe=1,function(e){(function(){var t={}.hasOwnProperty;function n(){for(var r="",c=0;c<arguments.length;c++){var i=arguments[c];i&&(r=s(r,o.call(this,i)))}return r}function o(r){if(typeof r=="string"||typeof r=="number")return this&&this[r]||r;if(typeof r!="object")return"";if(Array.isArray(r))return n.apply(this,r);if(r.toString!==Object.prototype.toString&&!r.toString.toString().includes("[native code]"))return r.toString();var c="";for(var i in r)t.call(r,i)&&r[i]&&(c=s(c,this&&this[i]||i));return c}function s(r,c){return c?r?r+" "+c:r+c:r}e.exports?(n.default=n,e.exports=n):window.classNames=n})()}(X)),X.exports}var $t=Ft();const oe=Pt($t),Dt={"purpur-tab-content":"_purpur-tab-content_1ugbi_1","purpur-tab-content--force-mount":"_purpur-tab-content--force-mount_1ugbi_15"},Lt=oe.bind(Dt),pe="purpur-tab-content",Vt=v.forwardRef(({children:e,tabId:t,"data-testid":n,className:o,disableForceMount:s,...r},c)=>d.jsx(Mt,{ref:c,className:Lt([pe,o,{[`${pe}--force-mount`]:!s}]),"data-testid":n,value:t,forceMount:!s||void 0,...r,children:e})),Bt=e=>!!e&&v.isValidElement(e)&&!!e.props.name&&!!e.props.tabId,Ut={"purpur-tab-header":"_purpur-tab-header_ebsfx_1","purpur-tab-header--contained":"_purpur-tab-header--contained_ebsfx_36","purpur-tab-header--contained-negative":"_purpur-tab-header--contained-negative_ebsfx_36","purpur-tab-header--line":"_purpur-tab-header--line_ebsfx_39","purpur-tab-header--line-negative":"_purpur-tab-header--line-negative_ebsfx_51"},Gt=oe.bind(Ut),me="purpur-tab-header",Wt=v.forwardRef(({index:e,tabId:t,variant:n,negative:o,onFocus:s,"data-testid":r,children:c},i)=>d.jsx(Ot,{id:`${t}-trigger`,className:Gt([me,`${me}--${n}${o?"-negative":""}`]),value:t,"data-testid":r,"data-index":e,ref:i,onFocus:s,children:c})),kt={"purpur-tabs__wrapper":"_purpur-tabs__wrapper_j1jjc_1","purpur-tabs__scroll-button":"_purpur-tabs__scroll-button_j1jjc_9","purpur-tabs__scroll-button--left":"_purpur-tabs__scroll-button--left_j1jjc_71","purpur-tabs__scroll-button--right":"_purpur-tabs__scroll-button--right_j1jjc_74","purpur-tabs__wrapper--scroll-end":"_purpur-tabs__wrapper--scroll-end_j1jjc_77","purpur-tabs__wrapper--scroll-start":"_purpur-tabs__wrapper--scroll-start_j1jjc_80","purpur-tabs--line":"_purpur-tabs--line_j1jjc_83","purpur-tabs--line-negative":"_purpur-tabs--line-negative_j1jjc_83","purpur-tabs__selected-border":"_purpur-tabs__selected-border_j1jjc_91","purpur-tabs__content-wrapper":"_purpur-tabs__content-wrapper_j1jjc_115","purpur-tabs--contained":"_purpur-tabs--contained_j1jjc_123","purpur-tabs__list":"_purpur-tabs__list_j1jjc_123","purpur-tabs--contained-negative":"_purpur-tabs--contained-negative_j1jjc_123","purpur-tabs__content-container":"_purpur-tabs__content-container_j1jjc_126","purpur-tabs--fullWidth":"_purpur-tabs--fullWidth_j1jjc_136"},qt=["line","contained"],De=e=>new CustomEvent("tabChangeDetail",{detail:{value:e}}),P=oe.bind(kt),R="purpur-tabs",Kt=(e,t)=>{var l;if(typeof(e==null?void 0:e.getBoundingClientRect)!="function"||typeof(t==null?void 0:t.scroll)!="function")return;const n=e.getBoundingClientRect(),o=t.getBoundingClientRect(),s=t.clientWidth,r=parseInt((l=getComputedStyle(t).borderLeftWidth)==null?void 0:l.split("px")[0],10),c=o.left+(isNaN(r)?0:r);let i;n.right>o.right&&(i=n.left+t.scrollLeft,i=i+n.width-s+s*.1,i=i-c),n.left<o.left&&(i=n.left+t.scrollLeft,i=i-s*.1,i=i-c),i!==void 0&&t.scroll({left:i,behavior:"smooth"})},Le=({children:e,variant:t="line",negative:n=!1,fullWidth:o=!1,onChange:s,className:r,defaultValue:c,animateHeight:i=!1,"data-testid":l,value:u,..._})=>{const f=v.useRef(null),[b,g]=v.useState(-1),[p,h]=v.useState({}),[y,x]=v.useState(0),[C,O]=v.useState(0),w=v.Children.toArray(e).filter(Bt),I=v.useRef(null),D=v.useRef(new Array(w.length)),B=200,S=t==="line",Y=P([R,`${R}--${t}${n?"-negative":""}`,{[`${R}--fullWidth`]:o},r]),F=v.Children.map(w,({props:{tabId:m}})=>m),L=()=>{const m=F.findIndex(j=>j===c);return m>=0?m:0};v.useEffect(()=>{u&&U(w.findIndex(m=>m.props.tabId===u))},[w,u]);const[V,U]=v.useState(L);if(new Set(F).size!==F.length)throw new Error("tabId must be unique");const G=(m,j)=>j||l?`${j||l}-${m}`:void 0,W=()=>{if(!S)return;const m=D.current[V];x((m==null?void 0:m.offsetLeft)||0),O((m==null?void 0:m.getBoundingClientRect().width)||0)},T=m=>{S&&!u&&U(w.findIndex(j=>j.props.tabId===m)),s==null||s(De(m))},Ve=m=>{if(I!=null&&I.current){const{scrollLeft:j}=I.current,M=m==="left"?-200:B;I.current.scroll({left:j+M,behavior:"smooth"})}},se=({side:m})=>d.jsx("button",{className:P(`${R}__scroll-button`,`${R}__scroll-button--${m}`),onClick:()=>Ve(m),type:"button","aria-hidden":"true",tabIndex:-1,"data-testid":G("scroll-button"),children:d.jsx(_e,{svg:m==="left"?et:tt,size:"md"})});return v.useEffect(()=>{const m=()=>{if(f.current&&i){const M=f.current.offsetHeight;g(M)}},j=()=>{m(),W()};return m(),window.addEventListener("resize",j),()=>{window.removeEventListener("resize",j)}},[V,i]),v.useEffect(()=>{W()},[V,o,w.length,t]),v.useEffect(()=>{const m=E=>{if(E.every(N=>N.isIntersecting)&&E.length===w.length){h({});return}E.forEach(N=>{const ie=Number(N.target.getAttribute("data-index")),Be=ie===0,Ue=ie===w.length-1;h(Ge=>({...Ge,...Be&&{[`${R}__wrapper--scroll-end`]:!N.isIntersecting},...Ue&&{[`${R}__wrapper--scroll-start`]:!N.isIntersecting}}))})},j=new IntersectionObserver(m,{threshold:[.99],root:I.current}),M=D.current;return M.forEach(E=>j.observe(E)),()=>{M.forEach(E=>j.unobserve(E))}},[w.length]),d.jsx(Et,{defaultValue:c??w[0].props.tabId,onValueChange:T,"data-testid":l,className:Y,value:u,..._,children:d.jsxs("div",{className:P(`${R}__container`),children:[d.jsxs("div",{className:P([`${R}__wrapper`,p]),children:[d.jsxs(At,{ref:m=>{I.current=m},className:P(`${R}__list`),children:[v.Children.map(w,(m,j)=>{const{name:M,tabId:E,"data-testid":ce}=m.props;return d.jsx(Wt,{"data-testid":G("header",ce),index:j,tabId:E,ref:N=>{N&&(D.current[j]=N)},onFocus:N=>{Kt(N.target,I.current)},variant:t,negative:n,children:M})}),S&&d.jsx("div",{className:P(`${R}__selected-border`),style:{width:C,transform:`translateX(${y}px)`},"data-testid":G("selected-border")})]}),d.jsx(se,{side:"left"}),d.jsx(se,{side:"right"})]}),d.jsx("div",{className:i?P(`${R}__content-wrapper`):"",style:{height:i&&b>-1?`${b}px`:"auto"},children:d.jsx("div",{ref:f,className:P(`${R}__content-container`),children:v.Children.map(w,m=>m)})})]})})};Le.Content=Vt;exports.Tabs=Le;exports.createTabChangeDetailEvent=De;exports.tabsVariants=qt;
10
10
  //# sourceMappingURL=tabs.cjs.js.map