@3fn/core 14.0.0 → 14.1.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/.kiro/steering/Civitas-System-Overview.md +3 -12
- package/.kiro/steering/Spec-Feedback-Protocol.md +2 -11
- package/.kiro/steering/Task-Completion-Protocol.md +7 -7
- package/.kiro/steering/start-up-tasks.md +4 -4
- package/dist/ComponentTokens.android.kt +12 -12
- package/dist/ComponentTokens.ios.swift +12 -12
- package/dist/ComponentTokens.web.css +3 -3
- package/dist/DesignTokens.android.kt +1 -1
- package/dist/DesignTokens.dtcg.json +2 -2
- package/dist/DesignTokens.ios.swift +1 -1
- package/dist/DesignTokens.web.css +1 -1
- package/dist/android/DesignTokens.android.kt +1 -1
- package/dist/browser/designerpunk.esm.js +14 -9
- package/dist/browser/designerpunk.esm.min.js +7 -7
- package/dist/browser/designerpunk.umd.js +14 -9
- package/dist/browser/designerpunk.umd.min.js +12 -12
- package/dist/browser/tokens.css +3 -3
- package/dist/build/tokens/defineComponentTokens.d.ts +10 -0
- package/dist/build/tokens/defineComponentTokens.js +26 -0
- package/dist/components/core/Avatar-Base/avatar.tokens.d.ts +21 -26
- package/dist/components/core/Avatar-Base/avatar.tokens.js +31 -34
- package/dist/components/core/Avatar-Base/index.d.ts +1 -1
- package/dist/components/core/Avatar-Base/index.js +2 -2
- package/dist/components/core/Button-Icon/buttonIcon.tokens.d.ts +28 -14
- package/dist/components/core/Button-Icon/buttonIcon.tokens.js +35 -20
- package/dist/generators/TokenFileGenerator.js +7 -2
- package/dist/ios/DesignTokens.ios.swift +1 -1
- package/dist/tokens/component/progress.d.ts +65 -5
- package/dist/tokens/component/progress.js +79 -18
- package/dist/types/generated/TokenTypes.d.ts +1 -1
- package/dist/types/generated/TokenTypes.js +1 -1
- package/dist/web/DesignTokens.web.css +1 -1
- package/governance/BUILD-SYSTEM-SETUP.md +1 -2
- package/governance/Component-Development-Guide.md +1 -1
- package/governance/Component-Development-Standards.md +19 -18
- package/governance/Component-Family-Avatar.md +6 -6
- package/governance/Component-Family-Badge.md +19 -19
- package/governance/Component-Family-Button.md +26 -26
- package/governance/Component-Family-Chip.md +14 -14
- package/governance/Component-Family-Container.md +12 -12
- package/governance/Component-Family-Form-Inputs.md +61 -61
- package/governance/Component-Family-Icon.md +8 -8
- package/governance/Component-Family-Navigation.md +1 -1
- package/governance/Component-Inheritance-Structures.md +29 -28
- package/governance/Component-Readiness-Status.md +6 -7
- package/governance/Component-Templates.md +26 -26
- package/governance/Contract-System-Reference.md +1 -1
- package/governance/Process-Development-Workflow.md +4 -4
- package/governance/Process-File-Organization.md +1 -4
- package/governance/Process-Hook-Operations.md +6 -7
- package/governance/Process-Spec-Planning.md +8 -14
- package/governance/Rosetta-System-Architecture.md +7 -5
- package/governance/Token-Quick-Reference.md +35 -22
- package/governance/Web-Authoring-Standards.md +1 -1
- package/governance/classification-map.md +109 -3
- package/governance/completion-documentation-guide.md +14 -31
- package/governance/platform-implementation-guidelines.md +1 -2
- package/governance/release-management-system.md +28 -63
- package/package.json +2 -6
- package/src/build/tokens/__tests__/defineComponentTokens.test.ts +113 -0
- package/src/build/tokens/defineComponentTokens.ts +43 -1
- package/src/components/core/Avatar-Base/avatar.tokens.ts +31 -34
- package/src/components/core/Avatar-Base/index.ts +1 -1
- package/src/components/core/Button-Icon/buttonIcon.tokens.ts +43 -27
- package/src/generators/TokenFileGenerator.ts +7 -2
- package/src/tokens/__tests__/ProgressTokenCompliance.test.ts +5 -3
- package/src/tokens/__tests__/ProgressTokenFormulas.test.ts +11 -11
- package/src/tokens/__tests__/ProgressTokenTranslation.test.ts +22 -20
- package/src/tokens/component/progress.ts +83 -21
- package/src/types/generated/TokenTypes.ts +1 -1
- package/token-index/components.yaml +8 -8
- package/src/tools/release/__tests__/ChangeClassifier.test.ts +0 -133
- package/src/tools/release/__tests__/ChangeExtractor.test.ts +0 -222
- package/src/tools/release/__tests__/GitHubPublisher.test.ts +0 -240
- package/src/tools/release/__tests__/NotesRenderer.test.ts +0 -142
- package/src/tools/release/__tests__/NpmPublisher.test.ts +0 -289
- package/src/tools/release/__tests__/PipelineIntegration.test.ts +0 -188
- package/src/tools/release/__tests__/ReleasePipeline.test.ts +0 -192
- package/src/tools/release/__tests__/SemanticVersionValidator.test.ts +0 -49
- package/src/tools/release/__tests__/SummaryScanner.test.ts +0 -141
- package/src/tools/release/__tests__/TagResolver.test.ts +0 -91
- package/src/tools/release/__tests__/VersionCalculator.test.ts +0 -270
- package/src/tools/release/__tests__/helpers/NpmMockHelper.ts +0 -80
- package/src/tools/release/cli/ReleasePipeline.ts +0 -165
- package/src/tools/release/cli/release-tool.ts +0 -107
- package/src/tools/release/pipeline/ChangeClassifier.ts +0 -61
- package/src/tools/release/pipeline/ChangeExtractor.ts +0 -87
- package/src/tools/release/pipeline/NotesRenderer.ts +0 -66
- package/src/tools/release/pipeline/SummaryScanner.ts +0 -70
- package/src/tools/release/pipeline/TagResolver.ts +0 -40
- package/src/tools/release/pipeline/VersionCalculator.ts +0 -375
- package/src/tools/release/publishers/GitHubPublisher.ts +0 -228
- package/src/tools/release/publishers/NpmPublisher.ts +0 -196
- package/src/tools/release/release-config.json +0 -5
- package/src/tools/release/types/index.ts +0 -282
- package/src/tools/release/validators/SemanticVersionValidator.ts +0 -67
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";var DesignerPunk=(()=>{var Ue=Object.defineProperty,cr=Object.defineProperties,dr=Object.getOwnPropertyDescriptor,ur=Object.getOwnPropertyDescriptors,hr=Object.getOwnPropertyNames,It=Object.getOwnPropertySymbols;var Rt=Object.prototype.hasOwnProperty,pr=Object.prototype.propertyIsEnumerable;var zt=(n,i,e)=>i in n?Ue(n,i,{enumerable:!0,configurable:!0,writable:!0,value:e}):n[i]=e,V=(n,i)=>{for(var e in i||(i={}))Rt.call(i,e)&&zt(n,e,i[e]);if(It)for(var e of It(i))pr.call(i,e)&&zt(n,e,i[e]);return n},P=(n,i)=>cr(n,ur(i));var gr=(n,i)=>{for(var e in i)Ue(n,e,{get:i[e],enumerable:!0})},mr=(n,i,e,t)=>{if(i&&typeof i=="object"||typeof i=="function")for(let r of hr(i))!Rt.call(n,r)&&r!==e&&Ue(n,r,{get:()=>i[r],enumerable:!(t=dr(i,r))||t.enumerable});return n};var br=n=>mr(Ue({},"__esModule",{value:!0}),n);var Kn={};gr(Kn,{Avatar:()=>xn,AvatarBase:()=>kn,AvatarBaseElement:()=>j,BadgeCount:()=>Sn,BadgeCountBase:()=>ne,BadgeCountNotification:()=>se,BadgeLabel:()=>Cn,BadgeLabelBase:()=>re,BadgeNotification:()=>En,ButtonCTA:()=>ze,ButtonIcon:()=>Re,ButtonVerticalListItem:()=>ee,ButtonVerticalListSet:()=>te,CheckboxBase:()=>wn,CheckboxLegal:()=>An,ChipBase:()=>In,ChipBaseElement:()=>le,ChipFilter:()=>zn,ChipFilterElement:()=>ce,ChipInput:()=>Rn,ChipInputElement:()=>de,Container:()=>vn,ContainerBase:()=>fn,ContainerBaseWeb:()=>q,ContainerCard:()=>Bn,ContainerCardBase:()=>Ln,ContainerCardBaseWeb:()=>K,Icon:()=>mn,IconBase:()=>bn,IconBaseElement:()=>O,InputCheckboxBaseElement:()=>oe,InputCheckboxLegalElement:()=>ae,InputRadioBaseElement:()=>Z,InputRadioSetElement:()=>ue,InputTextBase:()=>Q,InputTextEmail:()=>Ee,InputTextPassword:()=>we,InputTextPhoneNumber:()=>Ie,NavHeader:()=>qn,NavHeaderApp:()=>xe,NavHeaderAppElement:()=>Gn,NavHeaderBase:()=>ye,NavHeaderPage:()=>ke,NavHeaderPageElement:()=>Wn,NavSegmentedChoiceBase:()=>fe,NavTabBarBase:()=>_e,PaginationBase:()=>Nn,ProgressBar:()=>jn,ProgressBarBase:()=>Ce,ProgressConnector:()=>Mn,ProgressIndicatorConnectorBase:()=>pe,ProgressIndicatorLabelBase:()=>ge,ProgressIndicatorNodeBase:()=>he,ProgressLabel:()=>Dn,ProgressNode:()=>Pn,ProgressPaginationBase:()=>me,ProgressStepperBase:()=>be,ProgressStepperDetailed:()=>ve,RadioBase:()=>Vn,RadioSet:()=>$n,SegmentedChoice:()=>Fn,StepperBase:()=>Hn,StepperDetailed:()=>On,TabBar:()=>Un,TextInputField:()=>Tn,VerticalListButtonItem:()=>_n,VerticalListButtonSet:()=>yn});function it(n){let i=n.r/255,e=n.g/255,t=n.b/255,r=Math.max(i,e,t),s=Math.min(i,e,t),o=r-s,a=0,l=0,c=(r+s)/2;if(o!==0)switch(l=c>.5?o/(2-r-s):o/(r+s),r){case i:a=((e-t)/o+(e<t?6:0))/6;break;case e:a=((t-i)/o+2)/6;break;case t:a=((i-e)/o+4)/6;break}return{h:Math.round(a*360),s:Number(l.toFixed(4)),l:Number(c.toFixed(4))}}function rt(n){let i=n.h/360,e=n.s,t=n.l,r,s,o;if(e===0)r=s=o=t;else{let a=(d,h,u)=>(u<0&&(u+=1),u>1&&(u-=1),u<.16666666666666666?d+(h-d)*6*u:u<.5?h:u<.6666666666666666?d+(h-d)*(.6666666666666666-u)*6:d),l=t<.5?t*(1+e):t+e-t*e,c=2*t-l;r=a(c,l,i+1/3),s=a(c,l,i),o=a(c,l,i-1/3)}return{r:Math.round(r*255),g:Math.round(s*255),b:Math.round(o*255)}}function X(n){let i=n.match(/^rgba?\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)/);if(i)return{r:parseInt(i[1]),g:parseInt(i[2]),b:parseInt(i[3])};let e=n.replace(/^#/,"");if(!/^[0-9A-Fa-f]{3}$|^[0-9A-Fa-f]{6}$/.test(e))throw new Error(`Invalid hex color: ${n}`);let t=e.length===3?e.split("").map(a=>a+a).join(""):e,r=parseInt(t.substring(0,2),16),s=parseInt(t.substring(2,4),16),o=parseInt(t.substring(4,6),16);return{r,g:s,b:o}}function J(n){let i=e=>{let t=Math.round(Math.max(0,Math.min(255,e))).toString(16);return t.length===1?"0"+t:t};return`#${i(n.r)}${i(n.g)}${i(n.b)}`.toUpperCase()}function qe(n,i){let e={r:0,g:0,b:0},t=n.r*(1-i)+e.r*i,r=n.g*(1-i)+e.g*i,s=n.b*(1-i)+e.b*i;return{r:Math.round(Math.max(0,Math.min(255,t))),g:Math.round(Math.max(0,Math.min(255,r))),b:Math.round(Math.max(0,Math.min(255,s)))}}function Ge(n,i){let e={r:255,g:255,b:255},t=n.r*(1-i)+e.r*i,r=n.g*(1-i)+e.g*i,s=n.b*(1-i)+e.b*i;return{r:Math.round(Math.max(0,Math.min(255,t))),g:Math.round(Math.max(0,Math.min(255,r))),b:Math.round(Math.max(0,Math.min(255,s)))}}function We(n,i){let e=it(n);return e.s=Math.max(0,Math.min(1,e.s+i)),rt(e)}function je(n,i){let e=it(n);return e.s=Math.max(0,Math.min(1,e.s-i)),rt(e)}var z=.04;function $e(n){return{web:{value:n,unit:"unitless"},ios:{value:n,unit:"unitless"},android:{value:n,unit:"unitless"}}}var vr={blend100:{name:"blend100",category:"blend",baseValue:z,familyBaseValue:z,description:"Subtle modification - gentle feedback, container hover",mathematicalRelationship:"base \xD7 1 = 0.04 \xD7 1 = 0.04",baselineGridAlignment:!1,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:$e(z)},blend200:{name:"blend200",category:"blend",baseValue:z*2,familyBaseValue:z,description:"Standard modification - noticeable feedback, button hover",mathematicalRelationship:"base \xD7 2 = 0.04 \xD7 2 = 0.08",baselineGridAlignment:!1,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:$e(z*2)},blend300:{name:"blend300",category:"blend",baseValue:z*3,familyBaseValue:z,description:"Strong modification - clear feedback, pressed state",mathematicalRelationship:"base \xD7 3 = 0.04 \xD7 3 = 0.12",baselineGridAlignment:!1,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:$e(z*3)},blend400:{name:"blend400",category:"blend",baseValue:z*4,familyBaseValue:z,description:"Very strong modification - emphasized feedback",mathematicalRelationship:"base \xD7 4 = 0.04 \xD7 4 = 0.16",baselineGridAlignment:!1,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:$e(z*4)},blend500:{name:"blend500",category:"blend",baseValue:z*5,familyBaseValue:z,description:"Maximum modification - dramatic feedback",mathematicalRelationship:"base \xD7 5 = 0.04 \xD7 5 = 0.20",baselineGridAlignment:!1,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:$e(z*5)}},ts=Object.keys(vr);var Se={hoverDarker:.08,pressedDarker:.12,focusSaturate:.08,disabledDesaturate:.12,iconLighter:.08};function nt(n,i){try{let e=X(n),t=qe(e,i);return J(t)}catch(e){return n}}function Bt(n,i){try{let e=X(n),t=Ge(e,i);return J(t)}catch(e){return n}}function Lt(n,i){try{let e=X(n),t=We(e,i);return J(t)}catch(e){return n}}function Vt(n,i){try{let e=X(n),t=je(e,i);return J(t)}catch(e){return n}}function $t(){return{hoverColor:n=>nt(n,Se.hoverDarker),pressedColor:n=>nt(n,Se.pressedDarker),focusColor:n=>Lt(n,Se.focusSaturate),disabledColor:n=>Vt(n,Se.disabledDesaturate),iconColor:n=>Bt(n,Se.iconLighter),darkerBlend:nt,lighterBlend:Bt,saturate:Lt,desaturate:Vt}}function E(){return $t()}function st(n){let i=n.isFocused||n.isFilled,e;return n.hasError?e="color.error":n.isSuccess?e="color.success":n.isFocused?e="color.primary":e="color.text.muted",{isFloated:i,fontSize:i?"typography.labelMdFloat":"typography.labelMd",color:e,position:i?"above":"inside"}}function ot(n){let i=n.isLabelFloated;return{showErrorIcon:n.hasError&&i,showSuccessIcon:n.isSuccess&&i,showInfoIcon:!!n.showInfoIcon&&(n.isFocused||n.isFilled)}}function Pt(n){let i=n.value.length>0,e=!!n.errorMessage,t=!!n.isSuccess;return{isFocused:!1,isFilled:i,hasError:e,isSuccess:t,isLabelFloated:i,showInfoIcon:n.showInfoIcon}}function Mt(n){return P(V({},n),{isFocused:!0,isLabelFloated:!0})}function Dt(n){return P(V({},n),{isFocused:!1,isLabelFloated:n.isFilled})}function at(n,i){let e=i.length>0;return P(V({},n),{isFilled:e,isLabelFloated:n.isFocused||e})}function lt(n,i,e){return P(V({},n),{hasError:!!i,isSuccess:!!e})}var Nt=E();function Ht(n){let i={"arrow-right":'<line x1="5" y1="12" x2="19" y2="12"></line><polyline points="12 5 19 12 12 19"></polyline>',"arrow-left":'<line x1="19" y1="12" x2="5" y2="12"></line><polyline points="12 19 5 12 12 5"></polyline>',"arrow-up":'<line x1="12" y1="19" x2="12" y2="5"></line><polyline points="5 12 12 5 19 12"></polyline>',"arrow-down":'<line x1="12" y1="5" x2="12" y2="19"></line><polyline points="19 12 12 19 5 12"></polyline>',"chevron-right":'<polyline points="9 18 15 12 9 6"></polyline>',"chevron-left":'<polyline points="15 18 9 12 15 6"></polyline>',"chevron-down":'<polyline points="6 9 12 15 18 9"></polyline>',"external-link":'<path d="M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6"></path><polyline points="15 3 21 3 21 9"></polyline><line x1="10" y1="14" x2="21" y2="3"></line>',check:'<polyline points="20 6 9 17 4 12"></polyline>',"check-circle":'<path d="M22 11.08V12a10 10 0 1 1-5.93-9.14"></path><polyline points="22 4 12 14.01 9 11.01"></polyline>',x:'<line x1="18" y1="6" x2="6" y2="18"></line><line x1="6" y1="6" x2="18" y2="18"></line>',"x-circle":'<circle cx="12" cy="12" r="10"></circle><line x1="15" y1="9" x2="9" y2="15"></line><line x1="9" y1="9" x2="15" y2="15"></line>',plus:'<line x1="12" y1="5" x2="12" y2="19"></line><line x1="5" y1="12" x2="19" y2="12"></line>',minus:'<line x1="5" y1="12" x2="19" y2="12"></line>',save:'<path d="M19 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h11l5 5v11a2 2 0 0 1-2 2z"></path><polyline points="17 21 17 13 7 13 7 21"></polyline><polyline points="7 3 7 8 15 8"></polyline>',search:'<circle cx="11" cy="11" r="8"></circle><line x1="21" y1="21" x2="16.65" y2="16.65"></line>',filter:'<polygon points="22 3 2 3 10 12.46 10 19 14 21 14 12.46 22 3"></polygon>',"refresh-cw":'<polyline points="23 4 23 10 17 10"></polyline><polyline points="1 20 1 14 7 14"></polyline><path d="M3.51 9a9 9 0 0 1 14.85-3.36L23 10M1 14l4.64 4.36A9 9 0 0 0 20.49 15"></path>',share:'<path d="M4 12v8a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-8"></path><polyline points="16 6 12 2 8 6"></polyline><line x1="12" y1="2" x2="12" y2="15"></line>',"share-2":'<circle cx="18" cy="5" r="3"></circle><circle cx="6" cy="12" r="3"></circle><circle cx="18" cy="19" r="3"></circle><line x1="8.59" y1="13.51" x2="15.42" y2="17.49"></line><line x1="15.41" y1="6.51" x2="8.59" y2="10.49"></line>',"more-horizontal":'<circle cx="12" cy="12" r="1"></circle><circle cx="19" cy="12" r="1"></circle><circle cx="5" cy="12" r="1"></circle>',"more-vertical":'<circle cx="12" cy="12" r="1"></circle><circle cx="12" cy="5" r="1"></circle><circle cx="12" cy="19" r="1"></circle>',info:'<circle cx="12" cy="12" r="10"></circle><line x1="12" y1="16" x2="12" y2="12"></line><line x1="12" y1="8" x2="12.01" y2="8"></line>',"alert-circle":'<circle cx="12" cy="12" r="10"></circle><line x1="12" y1="8" x2="12" y2="12"></line><line x1="12" y1="16" x2="12.01" y2="16"></line>',shield:'<path d="M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z"></path>',eye:'<path d="M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z"></path><circle cx="12" cy="12" r="3"></circle>',"eye-off":'<path d="M17.94 17.94A10.07 10.07 0 0 1 12 20c-7 0-11-8-11-8a18.45 18.45 0 0 1 5.06-5.94M9.9 4.24A9.12 9.12 0 0 1 12 4c7 0 11 8 11 8a18.5 18.5 0 0 1-2.16 3.19m-6.72-1.07a3 3 0 1 1-4.24-4.24"></path><line x1="1" y1="1" x2="23" y2="23"></line>',circle:'<circle cx="12" cy="12" r="10"></circle>',heart:'<path d="M20.84 4.61a5.5 5.5 0 0 0-7.78 0L12 5.67l-1.06-1.06a5.5 5.5 0 0 0-7.78 7.78l1.06 1.06L12 21.23l7.78-7.78 1.06-1.06a5.5 5.5 0 0 0 0-7.78z"></path>',star:'<polygon points="12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2"></polygon>',smile:'<circle cx="12" cy="12" r="10"></circle><path d="M8 14s1.5 2 4 2 4-2 4-2"></path><line x1="9" y1="9" x2="9.01" y2="9"></line><line x1="15" y1="9" x2="15.01" y2="9"></line>',bell:'<path d="M18 8A6 6 0 0 0 6 8c0 7-3 9-3 9h18s-3-2-3-9"></path><path d="M13.73 21a2 2 0 0 1-3.46 0"></path>',user:'<path d="M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2"></path><circle cx="12" cy="7" r="4"></circle>',users:'<path d="M17 21v-2a4 4 0 0 0-4-4H5a4 4 0 0 0-4 4v2"></path><circle cx="9" cy="7" r="4"></circle><path d="M23 21v-2a4 4 0 0 0-3-3.87"></path><path d="M16 3.13a4 4 0 0 1 0 7.75"></path>',"user-check":'<path d="M16 21v-2a4 4 0 0 0-4-4H5a4 4 0 0 0-4 4v2"></path><circle cx="8.5" cy="7" r="4"></circle><polyline points="17 11 19 13 23 9"></polyline>',"user-x":'<path d="M16 21v-2a4 4 0 0 0-4-4H5a4 4 0 0 0-4 4v2"></path><circle cx="8.5" cy="7" r="4"></circle><line x1="18" y1="8" x2="23" y2="13"></line><line x1="23" y1="8" x2="18" y2="13"></line>',settings:'<circle cx="12" cy="12" r="3"></circle><path d="M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 0 1 0 2.83 2 2 0 0 1-2.83 0l-.06-.06a1.65 1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 0 1-2 2 2 2 0 0 1-2-2v-.09A1.65 1.65 0 0 0 9 19.4a1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 0 1-2.83 0 2 2 0 0 1 0-2.83l.06-.06a1.65 1.65 0 0 0 .33-1.82 1.65 1.65 0 0 0-1.51-1H3a2 2 0 0 1-2-2 2 2 0 0 1 2-2h.09A1.65 1.65 0 0 0 4.6 9a1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 0 1 0-2.83 2 2 0 0 1 2.83 0l.06.06a1.65 1.65 0 0 0 1.82.33H9a1.65 1.65 0 0 0 1-1.51V3a2 2 0 0 1 2-2 2 2 0 0 1 2 2v.09a1.65 1.65 0 0 0 1 1.51 1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 0 1 2.83 0 2 2 0 0 1 0 2.83l-.06.06a1.65 1.65 0 0 0-.33 1.82V9a1.65 1.65 0 0 0 1.51 1H21a2 2 0 0 1 2 2 2 2 0 0 1-2 2h-.09a1.65 1.65 0 0 0-1.51 1z"></path>',mail:'<path d="M4 4h16c1.1 0 2 .9 2 2v12c0 1.1-.9 2-2 2H4c-1.1 0-2-.9-2-2V6c0-1.1.9-2 2-2z"></path><polyline points="22,6 12,13 2,6"></polyline>',calendar:'<rect x="3" y="4" width="18" height="18" rx="2" ry="2"></rect><line x1="16" y1="2" x2="16" y2="6"></line><line x1="8" y1="2" x2="8" y2="6"></line><line x1="3" y1="10" x2="21" y2="10"></line>',clock:'<circle cx="12" cy="12" r="10"></circle><polyline points="12 6 12 12 16 14"></polyline>',phone:'<path d="M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72 12.84 12.84 0 0 0 .7 2.81 2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45 12.84 12.84 0 0 0 2.81.7A2 2 0 0 1 22 16.92z"></path>',smartphone:'<rect x="5" y="2" width="14" height="20" rx="2" ry="2"></rect><line x1="12" y1="18" x2="12.01" y2="18"></line>',globe:'<circle cx="12" cy="12" r="10"></circle><line x1="2" y1="12" x2="22" y2="12"></line><path d="M12 2a15.3 15.3 0 0 1 4 10 15.3 15.3 0 0 1-4 10 15.3 15.3 0 0 1-4-10 15.3 15.3 0 0 1 4-10z"></path>',"map-pin":'<path d="M21 10c0 7-9 13-9 13s-9-6-9-13a9 9 0 0 1 18 0z"></path><circle cx="12" cy="10" r="3"></circle>',briefcase:'<rect x="2" y="7" width="20" height="14" rx="2" ry="2"></rect><path d="M16 21V5a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16"></path>',"credit-card":'<rect x="1" y="4" width="22" height="16" rx="2" ry="2"></rect><line x1="1" y1="10" x2="23" y2="10"></line>',"dollar-sign":'<line x1="12" y1="1" x2="12" y2="23"></line><path d="M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6"></path>',"file-text":'<path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"></path><polyline points="14 2 14 8 20 8"></polyline><line x1="16" y1="13" x2="8" y2="13"></line><line x1="16" y1="17" x2="8" y2="17"></line><polyline points="10 9 9 9 8 9"></polyline>',award:'<circle cx="12" cy="8" r="7"></circle><polyline points="8.21 13.89 7 23 12 20 17 23 15.79 13.88"></polyline>',"trending-up":'<polyline points="23 6 13.5 15.5 8.5 10.5 1 18"></polyline><polyline points="17 6 23 6 23 12"></polyline>',wifi:'<path d="M5 12.55a11 11 0 0 1 14.08 0"></path><path d="M1.42 9a16 16 0 0 1 21.16 0"></path><path d="M8.53 16.11a6 6 0 0 1 6.95 0"></path><line x1="12" y1="20" x2="12.01" y2="20"></line>'};return i[n]||i.circle}function D(n){let{name:i,size:e,className:t="",style:r={},testID:s,color:o="inherit",opticalBalance:a=!1}=n,l=Ht(i),c={13:16,20:20,24:24,28:28,32:32,36:36,40:40,44:44,48:48},d=c[e];if(d===void 0)throw new Error(`Invalid icon size: ${e}. Valid sizes are: ${Object.keys(c).join(", ")}. Ensure you're using a valid IconBaseSize value (13, 20, 24, 28, 32, 36, 40, 44, 48).`);let m=`icon-base ${{13:"icon-base--size-050",20:"icon-base--size-075",24:"icon-base--size-100",28:"icon-base--size-125",32:"icon-base--size-200",36:"icon-base--size-400",40:"icon-base--size-500",44:"icon-base--size-600",48:"icon-base--size-700"}[e]} icon-base-${i} ${t}`.trim(),g;o==="inherit"?g="currentColor":a&&o.startsWith("#")?g=Nt.iconColor(o):o.startsWith("#")?g=o:g=`var(--${o})`;let f="var(--icon-stroke-width)",b=Object.entries(r).map(([_,S])=>`${_.replace(/([A-Z])/g,"-$1").toLowerCase()}: ${S}`).join("; "),x=s?` data-testid="${s}"`:"",C=b?` style="${b}"`:"";return`<svg width="${d}" height="${d}" viewBox="0 0 24 24" fill="none" stroke="${g}" stroke-width="${f}" stroke-linecap="round" stroke-linejoin="round" class="${m}" aria-hidden="true"${x}${C}>${l}</svg>`}var O=class extends HTMLElement{static get observedAttributes(){return["name","size","color","test-id","optical-balance"]}constructor(){super(),this._shadowRoot=this.attachShadow({mode:"open"})}connectedCallback(){this.render()}attributeChangedCallback(i,e,t){e!==t&&this.isConnected&&this.render()}get name(){return this.getAttribute("name")||"circle"}set name(i){this.setAttribute("name",i)}get size(){let i=this.getAttribute("size");if(!i)throw new Error('Missing required "size" attribute on <icon-base>. Valid sizes are: 13, 18, 24, 28, 32, 36, 40, 44, 48.');let e=parseInt(i,10),t=[13,20,24,28,32,36,40,44,48];if(!t.includes(e))throw new Error(`Invalid icon size: ${e}. Valid sizes are: ${t.join(", ")}. Ensure you're using a valid IconBaseSize value.`);return e}set size(i){this.setAttribute("size",i.toString())}get color(){return this.getAttribute("color")||"inherit"}set color(i){this.setAttribute("color",i)}get testID(){return this.getAttribute("test-id")}set testID(i){i?this.setAttribute("test-id",i):this.removeAttribute("test-id")}get opticalBalance(){return this.getAttribute("optical-balance")==="true"}set opticalBalance(i){i?this.setAttribute("optical-balance","true"):this.removeAttribute("optical-balance")}render(){let i=this.name,e=this.size,t=this.color,r=this.testID,s=this.opticalBalance,o=Ht(i),l={13:"icon-base--size-050",20:"icon-base--size-075",24:"icon-base--size-100",28:"icon-base--size-125",32:"icon-base--size-200",36:"icon-base--size-400",40:"icon-base--size-500",44:"icon-base--size-600",48:"icon-base--size-700"}[e],c;t==="inherit"?c="currentColor":s&&t.startsWith("#")?c=Nt.iconColor(t):t.startsWith("#")?c=t:c=`var(--${t})`;let d="var(--icon-stroke-width)",h=r?` data-testid="${r}"`:"",u=`
|
|
1
|
+
"use strict";var DesignerPunk=(()=>{var Ue=Object.defineProperty,cr=Object.defineProperties,dr=Object.getOwnPropertyDescriptor,ur=Object.getOwnPropertyDescriptors,hr=Object.getOwnPropertyNames,It=Object.getOwnPropertySymbols;var Rt=Object.prototype.hasOwnProperty,pr=Object.prototype.propertyIsEnumerable;var zt=(n,i,e)=>i in n?Ue(n,i,{enumerable:!0,configurable:!0,writable:!0,value:e}):n[i]=e,V=(n,i)=>{for(var e in i||(i={}))Rt.call(i,e)&&zt(n,e,i[e]);if(It)for(var e of It(i))pr.call(i,e)&&zt(n,e,i[e]);return n},P=(n,i)=>cr(n,ur(i));var gr=(n,i)=>{for(var e in i)Ue(n,e,{get:i[e],enumerable:!0})},mr=(n,i,e,t)=>{if(i&&typeof i=="object"||typeof i=="function")for(let r of hr(i))!Rt.call(n,r)&&r!==e&&Ue(n,r,{get:()=>i[r],enumerable:!(t=dr(i,r))||t.enumerable});return n};var br=n=>mr(Ue({},"__esModule",{value:!0}),n);var Kn={};gr(Kn,{Avatar:()=>xn,AvatarBase:()=>kn,AvatarBaseElement:()=>W,BadgeCount:()=>Sn,BadgeCountBase:()=>ne,BadgeCountNotification:()=>se,BadgeLabel:()=>Cn,BadgeLabelBase:()=>re,BadgeNotification:()=>En,ButtonCTA:()=>ze,ButtonIcon:()=>Re,ButtonVerticalListItem:()=>ee,ButtonVerticalListSet:()=>te,CheckboxBase:()=>wn,CheckboxLegal:()=>An,ChipBase:()=>In,ChipBaseElement:()=>le,ChipFilter:()=>zn,ChipFilterElement:()=>ce,ChipInput:()=>Rn,ChipInputElement:()=>de,Container:()=>vn,ContainerBase:()=>fn,ContainerBaseWeb:()=>q,ContainerCard:()=>Bn,ContainerCardBase:()=>Ln,ContainerCardBaseWeb:()=>j,Icon:()=>mn,IconBase:()=>bn,IconBaseElement:()=>O,InputCheckboxBaseElement:()=>oe,InputCheckboxLegalElement:()=>ae,InputRadioBaseElement:()=>K,InputRadioSetElement:()=>ue,InputTextBase:()=>J,InputTextEmail:()=>Ee,InputTextPassword:()=>we,InputTextPhoneNumber:()=>Ie,NavHeader:()=>qn,NavHeaderApp:()=>xe,NavHeaderAppElement:()=>Gn,NavHeaderBase:()=>ye,NavHeaderPage:()=>ke,NavHeaderPageElement:()=>Wn,NavSegmentedChoiceBase:()=>fe,NavTabBarBase:()=>_e,PaginationBase:()=>Nn,ProgressBar:()=>jn,ProgressBarBase:()=>Ce,ProgressConnector:()=>Mn,ProgressIndicatorConnectorBase:()=>pe,ProgressIndicatorLabelBase:()=>ge,ProgressIndicatorNodeBase:()=>he,ProgressLabel:()=>Dn,ProgressNode:()=>Pn,ProgressPaginationBase:()=>me,ProgressStepperBase:()=>be,ProgressStepperDetailed:()=>ve,RadioBase:()=>Vn,RadioSet:()=>$n,SegmentedChoice:()=>Fn,StepperBase:()=>Hn,StepperDetailed:()=>On,TabBar:()=>Un,TextInputField:()=>Tn,VerticalListButtonItem:()=>_n,VerticalListButtonSet:()=>yn});function it(n){let i=n.r/255,e=n.g/255,t=n.b/255,r=Math.max(i,e,t),s=Math.min(i,e,t),o=r-s,a=0,l=0,c=(r+s)/2;if(o!==0)switch(l=c>.5?o/(2-r-s):o/(r+s),r){case i:a=((e-t)/o+(e<t?6:0))/6;break;case e:a=((t-i)/o+2)/6;break;case t:a=((i-e)/o+4)/6;break}return{h:Math.round(a*360),s:Number(l.toFixed(4)),l:Number(c.toFixed(4))}}function rt(n){let i=n.h/360,e=n.s,t=n.l,r,s,o;if(e===0)r=s=o=t;else{let a=(d,h,u)=>(u<0&&(u+=1),u>1&&(u-=1),u<.16666666666666666?d+(h-d)*6*u:u<.5?h:u<.6666666666666666?d+(h-d)*(.6666666666666666-u)*6:d),l=t<.5?t*(1+e):t+e-t*e,c=2*t-l;r=a(c,l,i+1/3),s=a(c,l,i),o=a(c,l,i-1/3)}return{r:Math.round(r*255),g:Math.round(s*255),b:Math.round(o*255)}}function Y(n){let i=n.match(/^rgba?\(\s*(\d+)\s*,\s*(\d+)\s*,\s*(\d+)/);if(i)return{r:parseInt(i[1]),g:parseInt(i[2]),b:parseInt(i[3])};let e=n.replace(/^#/,"");if(!/^[0-9A-Fa-f]{3}$|^[0-9A-Fa-f]{6}$/.test(e))throw new Error(`Invalid hex color: ${n}`);let t=e.length===3?e.split("").map(a=>a+a).join(""):e,r=parseInt(t.substring(0,2),16),s=parseInt(t.substring(2,4),16),o=parseInt(t.substring(4,6),16);return{r,g:s,b:o}}function X(n){let i=e=>{let t=Math.round(Math.max(0,Math.min(255,e))).toString(16);return t.length===1?"0"+t:t};return`#${i(n.r)}${i(n.g)}${i(n.b)}`.toUpperCase()}function qe(n,i){let e={r:0,g:0,b:0},t=n.r*(1-i)+e.r*i,r=n.g*(1-i)+e.g*i,s=n.b*(1-i)+e.b*i;return{r:Math.round(Math.max(0,Math.min(255,t))),g:Math.round(Math.max(0,Math.min(255,r))),b:Math.round(Math.max(0,Math.min(255,s)))}}function Ge(n,i){let e={r:255,g:255,b:255},t=n.r*(1-i)+e.r*i,r=n.g*(1-i)+e.g*i,s=n.b*(1-i)+e.b*i;return{r:Math.round(Math.max(0,Math.min(255,t))),g:Math.round(Math.max(0,Math.min(255,r))),b:Math.round(Math.max(0,Math.min(255,s)))}}function We(n,i){let e=it(n);return e.s=Math.max(0,Math.min(1,e.s+i)),rt(e)}function je(n,i){let e=it(n);return e.s=Math.max(0,Math.min(1,e.s-i)),rt(e)}var z=.04;function $e(n){return{web:{value:n,unit:"unitless"},ios:{value:n,unit:"unitless"},android:{value:n,unit:"unitless"}}}var vr={blend100:{name:"blend100",category:"blend",baseValue:z,familyBaseValue:z,description:"Subtle modification - gentle feedback, container hover",mathematicalRelationship:"base \xD7 1 = 0.04 \xD7 1 = 0.04",baselineGridAlignment:!1,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:$e(z)},blend200:{name:"blend200",category:"blend",baseValue:z*2,familyBaseValue:z,description:"Standard modification - noticeable feedback, button hover",mathematicalRelationship:"base \xD7 2 = 0.04 \xD7 2 = 0.08",baselineGridAlignment:!1,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:$e(z*2)},blend300:{name:"blend300",category:"blend",baseValue:z*3,familyBaseValue:z,description:"Strong modification - clear feedback, pressed state",mathematicalRelationship:"base \xD7 3 = 0.04 \xD7 3 = 0.12",baselineGridAlignment:!1,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:$e(z*3)},blend400:{name:"blend400",category:"blend",baseValue:z*4,familyBaseValue:z,description:"Very strong modification - emphasized feedback",mathematicalRelationship:"base \xD7 4 = 0.04 \xD7 4 = 0.16",baselineGridAlignment:!1,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:$e(z*4)},blend500:{name:"blend500",category:"blend",baseValue:z*5,familyBaseValue:z,description:"Maximum modification - dramatic feedback",mathematicalRelationship:"base \xD7 5 = 0.04 \xD7 5 = 0.20",baselineGridAlignment:!1,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:$e(z*5)}},ts=Object.keys(vr);var Se={hoverDarker:.08,pressedDarker:.12,focusSaturate:.08,disabledDesaturate:.12,iconLighter:.08};function nt(n,i){try{let e=Y(n),t=qe(e,i);return X(t)}catch(e){return n}}function Bt(n,i){try{let e=Y(n),t=Ge(e,i);return X(t)}catch(e){return n}}function Lt(n,i){try{let e=Y(n),t=We(e,i);return X(t)}catch(e){return n}}function Vt(n,i){try{let e=Y(n),t=je(e,i);return X(t)}catch(e){return n}}function $t(){return{hoverColor:n=>nt(n,Se.hoverDarker),pressedColor:n=>nt(n,Se.pressedDarker),focusColor:n=>Lt(n,Se.focusSaturate),disabledColor:n=>Vt(n,Se.disabledDesaturate),iconColor:n=>Bt(n,Se.iconLighter),darkerBlend:nt,lighterBlend:Bt,saturate:Lt,desaturate:Vt}}function E(){return $t()}function st(n){let i=n.isFocused||n.isFilled,e;return n.hasError?e="color.error":n.isSuccess?e="color.success":n.isFocused?e="color.primary":e="color.text.muted",{isFloated:i,fontSize:i?"typography.labelMdFloat":"typography.labelMd",color:e,position:i?"above":"inside"}}function ot(n){let i=n.isLabelFloated;return{showErrorIcon:n.hasError&&i,showSuccessIcon:n.isSuccess&&i,showInfoIcon:!!n.showInfoIcon&&(n.isFocused||n.isFilled)}}function Pt(n){let i=n.value.length>0,e=!!n.errorMessage,t=!!n.isSuccess;return{isFocused:!1,isFilled:i,hasError:e,isSuccess:t,isLabelFloated:i,showInfoIcon:n.showInfoIcon}}function Mt(n){return P(V({},n),{isFocused:!0,isLabelFloated:!0})}function Dt(n){return P(V({},n),{isFocused:!1,isLabelFloated:n.isFilled})}function at(n,i){let e=i.length>0;return P(V({},n),{isFilled:e,isLabelFloated:n.isFocused||e})}function lt(n,i,e){return P(V({},n),{hasError:!!i,isSuccess:!!e})}var Nt=E();function Ht(n){let i={"arrow-right":'<line x1="5" y1="12" x2="19" y2="12"></line><polyline points="12 5 19 12 12 19"></polyline>',"arrow-left":'<line x1="19" y1="12" x2="5" y2="12"></line><polyline points="12 19 5 12 12 5"></polyline>',"arrow-up":'<line x1="12" y1="19" x2="12" y2="5"></line><polyline points="5 12 12 5 19 12"></polyline>',"arrow-down":'<line x1="12" y1="5" x2="12" y2="19"></line><polyline points="19 12 12 19 5 12"></polyline>',"chevron-right":'<polyline points="9 18 15 12 9 6"></polyline>',"chevron-left":'<polyline points="15 18 9 12 15 6"></polyline>',"chevron-down":'<polyline points="6 9 12 15 18 9"></polyline>',"external-link":'<path d="M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6"></path><polyline points="15 3 21 3 21 9"></polyline><line x1="10" y1="14" x2="21" y2="3"></line>',check:'<polyline points="20 6 9 17 4 12"></polyline>',"check-circle":'<path d="M22 11.08V12a10 10 0 1 1-5.93-9.14"></path><polyline points="22 4 12 14.01 9 11.01"></polyline>',x:'<line x1="18" y1="6" x2="6" y2="18"></line><line x1="6" y1="6" x2="18" y2="18"></line>',"x-circle":'<circle cx="12" cy="12" r="10"></circle><line x1="15" y1="9" x2="9" y2="15"></line><line x1="9" y1="9" x2="15" y2="15"></line>',plus:'<line x1="12" y1="5" x2="12" y2="19"></line><line x1="5" y1="12" x2="19" y2="12"></line>',minus:'<line x1="5" y1="12" x2="19" y2="12"></line>',save:'<path d="M19 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h11l5 5v11a2 2 0 0 1-2 2z"></path><polyline points="17 21 17 13 7 13 7 21"></polyline><polyline points="7 3 7 8 15 8"></polyline>',search:'<circle cx="11" cy="11" r="8"></circle><line x1="21" y1="21" x2="16.65" y2="16.65"></line>',filter:'<polygon points="22 3 2 3 10 12.46 10 19 14 21 14 12.46 22 3"></polygon>',"refresh-cw":'<polyline points="23 4 23 10 17 10"></polyline><polyline points="1 20 1 14 7 14"></polyline><path d="M3.51 9a9 9 0 0 1 14.85-3.36L23 10M1 14l4.64 4.36A9 9 0 0 0 20.49 15"></path>',share:'<path d="M4 12v8a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2v-8"></path><polyline points="16 6 12 2 8 6"></polyline><line x1="12" y1="2" x2="12" y2="15"></line>',"share-2":'<circle cx="18" cy="5" r="3"></circle><circle cx="6" cy="12" r="3"></circle><circle cx="18" cy="19" r="3"></circle><line x1="8.59" y1="13.51" x2="15.42" y2="17.49"></line><line x1="15.41" y1="6.51" x2="8.59" y2="10.49"></line>',"more-horizontal":'<circle cx="12" cy="12" r="1"></circle><circle cx="19" cy="12" r="1"></circle><circle cx="5" cy="12" r="1"></circle>',"more-vertical":'<circle cx="12" cy="12" r="1"></circle><circle cx="12" cy="5" r="1"></circle><circle cx="12" cy="19" r="1"></circle>',info:'<circle cx="12" cy="12" r="10"></circle><line x1="12" y1="16" x2="12" y2="12"></line><line x1="12" y1="8" x2="12.01" y2="8"></line>',"alert-circle":'<circle cx="12" cy="12" r="10"></circle><line x1="12" y1="8" x2="12" y2="12"></line><line x1="12" y1="16" x2="12.01" y2="16"></line>',shield:'<path d="M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z"></path>',eye:'<path d="M1 12s4-8 11-8 11 8 11 8-4 8-11 8-11-8-11-8z"></path><circle cx="12" cy="12" r="3"></circle>',"eye-off":'<path d="M17.94 17.94A10.07 10.07 0 0 1 12 20c-7 0-11-8-11-8a18.45 18.45 0 0 1 5.06-5.94M9.9 4.24A9.12 9.12 0 0 1 12 4c7 0 11 8 11 8a18.5 18.5 0 0 1-2.16 3.19m-6.72-1.07a3 3 0 1 1-4.24-4.24"></path><line x1="1" y1="1" x2="23" y2="23"></line>',circle:'<circle cx="12" cy="12" r="10"></circle>',heart:'<path d="M20.84 4.61a5.5 5.5 0 0 0-7.78 0L12 5.67l-1.06-1.06a5.5 5.5 0 0 0-7.78 7.78l1.06 1.06L12 21.23l7.78-7.78 1.06-1.06a5.5 5.5 0 0 0 0-7.78z"></path>',star:'<polygon points="12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2"></polygon>',smile:'<circle cx="12" cy="12" r="10"></circle><path d="M8 14s1.5 2 4 2 4-2 4-2"></path><line x1="9" y1="9" x2="9.01" y2="9"></line><line x1="15" y1="9" x2="15.01" y2="9"></line>',bell:'<path d="M18 8A6 6 0 0 0 6 8c0 7-3 9-3 9h18s-3-2-3-9"></path><path d="M13.73 21a2 2 0 0 1-3.46 0"></path>',user:'<path d="M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2"></path><circle cx="12" cy="7" r="4"></circle>',users:'<path d="M17 21v-2a4 4 0 0 0-4-4H5a4 4 0 0 0-4 4v2"></path><circle cx="9" cy="7" r="4"></circle><path d="M23 21v-2a4 4 0 0 0-3-3.87"></path><path d="M16 3.13a4 4 0 0 1 0 7.75"></path>',"user-check":'<path d="M16 21v-2a4 4 0 0 0-4-4H5a4 4 0 0 0-4 4v2"></path><circle cx="8.5" cy="7" r="4"></circle><polyline points="17 11 19 13 23 9"></polyline>',"user-x":'<path d="M16 21v-2a4 4 0 0 0-4-4H5a4 4 0 0 0-4 4v2"></path><circle cx="8.5" cy="7" r="4"></circle><line x1="18" y1="8" x2="23" y2="13"></line><line x1="23" y1="8" x2="18" y2="13"></line>',settings:'<circle cx="12" cy="12" r="3"></circle><path d="M19.4 15a1.65 1.65 0 0 0 .33 1.82l.06.06a2 2 0 0 1 0 2.83 2 2 0 0 1-2.83 0l-.06-.06a1.65 1.65 0 0 0-1.82-.33 1.65 1.65 0 0 0-1 1.51V21a2 2 0 0 1-2 2 2 2 0 0 1-2-2v-.09A1.65 1.65 0 0 0 9 19.4a1.65 1.65 0 0 0-1.82.33l-.06.06a2 2 0 0 1-2.83 0 2 2 0 0 1 0-2.83l.06-.06a1.65 1.65 0 0 0 .33-1.82 1.65 1.65 0 0 0-1.51-1H3a2 2 0 0 1-2-2 2 2 0 0 1 2-2h.09A1.65 1.65 0 0 0 4.6 9a1.65 1.65 0 0 0-.33-1.82l-.06-.06a2 2 0 0 1 0-2.83 2 2 0 0 1 2.83 0l.06.06a1.65 1.65 0 0 0 1.82.33H9a1.65 1.65 0 0 0 1-1.51V3a2 2 0 0 1 2-2 2 2 0 0 1 2 2v.09a1.65 1.65 0 0 0 1 1.51 1.65 1.65 0 0 0 1.82-.33l.06-.06a2 2 0 0 1 2.83 0 2 2 0 0 1 0 2.83l-.06.06a1.65 1.65 0 0 0-.33 1.82V9a1.65 1.65 0 0 0 1.51 1H21a2 2 0 0 1 2 2 2 2 0 0 1-2 2h-.09a1.65 1.65 0 0 0-1.51 1z"></path>',mail:'<path d="M4 4h16c1.1 0 2 .9 2 2v12c0 1.1-.9 2-2 2H4c-1.1 0-2-.9-2-2V6c0-1.1.9-2 2-2z"></path><polyline points="22,6 12,13 2,6"></polyline>',calendar:'<rect x="3" y="4" width="18" height="18" rx="2" ry="2"></rect><line x1="16" y1="2" x2="16" y2="6"></line><line x1="8" y1="2" x2="8" y2="6"></line><line x1="3" y1="10" x2="21" y2="10"></line>',clock:'<circle cx="12" cy="12" r="10"></circle><polyline points="12 6 12 12 16 14"></polyline>',phone:'<path d="M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72 12.84 12.84 0 0 0 .7 2.81 2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45 12.84 12.84 0 0 0 2.81.7A2 2 0 0 1 22 16.92z"></path>',smartphone:'<rect x="5" y="2" width="14" height="20" rx="2" ry="2"></rect><line x1="12" y1="18" x2="12.01" y2="18"></line>',globe:'<circle cx="12" cy="12" r="10"></circle><line x1="2" y1="12" x2="22" y2="12"></line><path d="M12 2a15.3 15.3 0 0 1 4 10 15.3 15.3 0 0 1-4 10 15.3 15.3 0 0 1-4-10 15.3 15.3 0 0 1 4-10z"></path>',"map-pin":'<path d="M21 10c0 7-9 13-9 13s-9-6-9-13a9 9 0 0 1 18 0z"></path><circle cx="12" cy="10" r="3"></circle>',briefcase:'<rect x="2" y="7" width="20" height="14" rx="2" ry="2"></rect><path d="M16 21V5a2 2 0 0 0-2-2h-4a2 2 0 0 0-2 2v16"></path>',"credit-card":'<rect x="1" y="4" width="22" height="16" rx="2" ry="2"></rect><line x1="1" y1="10" x2="23" y2="10"></line>',"dollar-sign":'<line x1="12" y1="1" x2="12" y2="23"></line><path d="M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6"></path>',"file-text":'<path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"></path><polyline points="14 2 14 8 20 8"></polyline><line x1="16" y1="13" x2="8" y2="13"></line><line x1="16" y1="17" x2="8" y2="17"></line><polyline points="10 9 9 9 8 9"></polyline>',award:'<circle cx="12" cy="8" r="7"></circle><polyline points="8.21 13.89 7 23 12 20 17 23 15.79 13.88"></polyline>',"trending-up":'<polyline points="23 6 13.5 15.5 8.5 10.5 1 18"></polyline><polyline points="17 6 23 6 23 12"></polyline>',wifi:'<path d="M5 12.55a11 11 0 0 1 14.08 0"></path><path d="M1.42 9a16 16 0 0 1 21.16 0"></path><path d="M8.53 16.11a6 6 0 0 1 6.95 0"></path><line x1="12" y1="20" x2="12.01" y2="20"></line>'};return i[n]||i.circle}function D(n){let{name:i,size:e,className:t="",style:r={},testID:s,color:o="inherit",opticalBalance:a=!1}=n,l=Ht(i),c={13:16,20:20,24:24,28:28,32:32,36:36,40:40,44:44,48:48},d=c[e];if(d===void 0)throw new Error(`Invalid icon size: ${e}. Valid sizes are: ${Object.keys(c).join(", ")}. Ensure you're using a valid IconBaseSize value (13, 20, 24, 28, 32, 36, 40, 44, 48).`);let m=`icon-base ${{13:"icon-base--size-050",20:"icon-base--size-075",24:"icon-base--size-100",28:"icon-base--size-125",32:"icon-base--size-200",36:"icon-base--size-400",40:"icon-base--size-500",44:"icon-base--size-600",48:"icon-base--size-700"}[e]} icon-base-${i} ${t}`.trim(),g;o==="inherit"?g="currentColor":a&&o.startsWith("#")?g=Nt.iconColor(o):o.startsWith("#")?g=o:g=`var(--${o})`;let f="var(--icon-stroke-width)",b=Object.entries(r).map(([_,S])=>`${_.replace(/([A-Z])/g,"-$1").toLowerCase()}: ${S}`).join("; "),x=s?` data-testid="${s}"`:"",C=b?` style="${b}"`:"";return`<svg width="${d}" height="${d}" viewBox="0 0 24 24" fill="none" stroke="${g}" stroke-width="${f}" stroke-linecap="round" stroke-linejoin="round" class="${m}" aria-hidden="true"${x}${C}>${l}</svg>`}var O=class extends HTMLElement{static get observedAttributes(){return["name","size","color","test-id","optical-balance"]}constructor(){super(),this._shadowRoot=this.attachShadow({mode:"open"})}connectedCallback(){this.render()}attributeChangedCallback(i,e,t){e!==t&&this.isConnected&&this.render()}get name(){return this.getAttribute("name")||"circle"}set name(i){this.setAttribute("name",i)}get size(){let i=this.getAttribute("size");if(!i)throw new Error('Missing required "size" attribute on <icon-base>. Valid sizes are: 13, 18, 24, 28, 32, 36, 40, 44, 48.');let e=parseInt(i,10),t=[13,20,24,28,32,36,40,44,48];if(!t.includes(e))throw new Error(`Invalid icon size: ${e}. Valid sizes are: ${t.join(", ")}. Ensure you're using a valid IconBaseSize value.`);return e}set size(i){this.setAttribute("size",i.toString())}get color(){return this.getAttribute("color")||"inherit"}set color(i){this.setAttribute("color",i)}get testID(){return this.getAttribute("test-id")}set testID(i){i?this.setAttribute("test-id",i):this.removeAttribute("test-id")}get opticalBalance(){return this.getAttribute("optical-balance")==="true"}set opticalBalance(i){i?this.setAttribute("optical-balance","true"):this.removeAttribute("optical-balance")}render(){let i=this.name,e=this.size,t=this.color,r=this.testID,s=this.opticalBalance,o=Ht(i),l={13:"icon-base--size-050",20:"icon-base--size-075",24:"icon-base--size-100",28:"icon-base--size-125",32:"icon-base--size-200",36:"icon-base--size-400",40:"icon-base--size-500",44:"icon-base--size-600",48:"icon-base--size-700"}[e],c;t==="inherit"?c="currentColor":s&&t.startsWith("#")?c=Nt.iconColor(t):t.startsWith("#")?c=t:c=`var(--${t})`;let d="var(--icon-stroke-width)",h=r?` data-testid="${r}"`:"",u=`
|
|
2
2
|
<style>
|
|
3
3
|
.icon-base {
|
|
4
4
|
display: inline-block;
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
>
|
|
42
42
|
${o}
|
|
43
43
|
</svg>
|
|
44
|
-
`}};customElements.get("icon-base")||customElements.define("icon-base",O);var A={size050:13,size075:20,size100:24,size125:32,size150:28,size200:32,size300:32,size400:36,size500:40,size600:44,size700:48},Ot=A;var Ft=":host{display:block;width:100%}.input-text-base{width:100%}.input-wrapper{position:relative;width:100%;min-height:var(--tap-area-comfortable)}.input-element{width:100%;min-height:var(--tap-area-comfortable);padding-top:var(--space-inset-200);padding-bottom:var(--space-inset-none);padding-left:var(--space-inset-100);padding-right:calc(var(--space-inset-100)+var(--icon-size-100)+var(--space-inset-100));font-family:var(--typography-input-font-family);font-size:var(--typography-input-font-size);line-height:var(--typography-input-line-height);font-weight:var(--typography-input-font-weight);letter-spacing:var(--typography-input-letter-spacing);color:var(--color-text-default);background:var(--color-structure-canvas);border:var(--border-default) solid var(--color-structure-border);border-radius:var(--radius-150);outline:none;box-sizing:border-box;transition:border-color var(--motion-float-label-duration) var(--motion-float-label-easing)}.input-element:focus{border-color:var(--_itb-focus-color,var(--color-action-primary))}.input-element:focus-visible{outline:var(--accessibility-focus-width) solid var(--accessibility-focus-color);outline-offset:var(--accessibility-focus-offset);transition:outline-color var(--motion-focus-transition-duration) var(--motion-focus-transition-easing)}.input-wrapper.error .input-element:focus-visible{outline-color:var(--accessibility-focus-color)}.input-wrapper.success .input-element:focus-visible{outline-color:var(--accessibility-focus-color)}.input-wrapper.error .input-element{border-color:var(--color-feedback-error-text)}.input-wrapper.success .input-element{border-color:var(--color-feedback-success-text)}.input-label{position:absolute;left:var(--space-inset-100);top:50%;transform:translateY(-50%);font-family:var(--typography-label-md-font-family);font-size:var(--typography-label-md-font-size);line-height:var(--typography-label-md-line-height);font-weight:var(--typography-label-md-font-weight);letter-spacing:var(--typography-label-md-letter-spacing);color:var(--color-text-muted);pointer-events:none;transition:transform var(--motion-float-label-duration) var(--motion-float-label-easing),font-size var(--motion-float-label-duration) var(--motion-float-label-easing),color var(--motion-float-label-duration) var(--motion-float-label-easing)}.input-label.floated{transform:translateY(calc(-100% - var(--space-grouped-tight)));font-size:var(--typography-label-md-float-font-size);line-height:var(--typography-label-md-float-line-height)}.input-wrapper.focused .input-label.floated{color:var(--_itb-focus-color,var(--color-action-primary))}.input-wrapper.error .input-label{color:var(--color-feedback-error-text)}.input-wrapper.success .input-label{color:var(--color-feedback-success-text)}.helper-text{margin:var(--space-grouped-minimal) 0 0 0;padding:0;font-family:var(--typography-caption-font-family);font-size:var(--typography-caption-font-size);line-height:var(--typography-caption-line-height);font-weight:var(--typography-caption-font-weight);letter-spacing:var(--typography-caption-letter-spacing);color:var(--color-text-muted)}.error-message{margin:var(--space-grouped-minimal) 0 0 0;padding:0;font-family:var(--typography-caption-font-family);font-size:var(--typography-caption-font-size);line-height:var(--typography-caption-line-height);font-weight:var(--typography-caption-font-weight);letter-spacing:var(--typography-caption-letter-spacing);color:var(--color-feedback-error-text)}.trailing-icon-container{position:absolute;right:var(--space-inset-100);top:50%;transform:translateY(-50%);display:flex;align-items:center;justify-content:center;pointer-events:none;opacity:0;transition:opacity var(--motion-float-label-duration) var(--motion-float-label-easing);transition-delay:var(--motion-float-label-duration)}.input-wrapper.focused .trailing-icon-container{opacity:1;transition-delay:var(--motion-float-label-duration)}.input-wrapper.filled .trailing-icon-container{opacity:1;transition-delay:var(--motion-float-label-duration)}.input-wrapper:not(.focused):not(.filled) .trailing-icon-container{opacity:0;transition-delay:0ms}.trailing-icon{display:block}@media (prefers-reduced-motion:reduce){.input-element,.input-element:focus-visible,.input-label,.trailing-icon-container{transition:none}}";var
|
|
44
|
+
`}};customElements.get("icon-base")||customElements.define("icon-base",O);var A={size050:13,size075:20,size100:24,size125:32,size150:28,size200:32,size300:32,size400:36,size500:40,size600:44,size700:48},Ot=A;var Ft=":host{display:block;width:100%}.input-text-base{width:100%}.input-wrapper{position:relative;width:100%;min-height:var(--tap-area-comfortable)}.input-element{width:100%;min-height:var(--tap-area-comfortable);padding-top:var(--space-inset-200);padding-bottom:var(--space-inset-none);padding-left:var(--space-inset-100);padding-right:calc(var(--space-inset-100)+var(--icon-size-100)+var(--space-inset-100));font-family:var(--typography-input-font-family);font-size:var(--typography-input-font-size);line-height:var(--typography-input-line-height);font-weight:var(--typography-input-font-weight);letter-spacing:var(--typography-input-letter-spacing);color:var(--color-text-default);background:var(--color-structure-canvas);border:var(--border-default) solid var(--color-structure-border);border-radius:var(--radius-150);outline:none;box-sizing:border-box;transition:border-color var(--motion-float-label-duration) var(--motion-float-label-easing)}.input-element:focus{border-color:var(--_itb-focus-color,var(--color-action-primary))}.input-element:focus-visible{outline:var(--accessibility-focus-width) solid var(--accessibility-focus-color);outline-offset:var(--accessibility-focus-offset);transition:outline-color var(--motion-focus-transition-duration) var(--motion-focus-transition-easing)}.input-wrapper.error .input-element:focus-visible{outline-color:var(--accessibility-focus-color)}.input-wrapper.success .input-element:focus-visible{outline-color:var(--accessibility-focus-color)}.input-wrapper.error .input-element{border-color:var(--color-feedback-error-text)}.input-wrapper.success .input-element{border-color:var(--color-feedback-success-text)}.input-label{position:absolute;left:var(--space-inset-100);top:50%;transform:translateY(-50%);font-family:var(--typography-label-md-font-family);font-size:var(--typography-label-md-font-size);line-height:var(--typography-label-md-line-height);font-weight:var(--typography-label-md-font-weight);letter-spacing:var(--typography-label-md-letter-spacing);color:var(--color-text-muted);pointer-events:none;transition:transform var(--motion-float-label-duration) var(--motion-float-label-easing),font-size var(--motion-float-label-duration) var(--motion-float-label-easing),color var(--motion-float-label-duration) var(--motion-float-label-easing)}.input-label.floated{transform:translateY(calc(-100% - var(--space-grouped-tight)));font-size:var(--typography-label-md-float-font-size);line-height:var(--typography-label-md-float-line-height)}.input-wrapper.focused .input-label.floated{color:var(--_itb-focus-color,var(--color-action-primary))}.input-wrapper.error .input-label{color:var(--color-feedback-error-text)}.input-wrapper.success .input-label{color:var(--color-feedback-success-text)}.helper-text{margin:var(--space-grouped-minimal) 0 0 0;padding:0;font-family:var(--typography-caption-font-family);font-size:var(--typography-caption-font-size);line-height:var(--typography-caption-line-height);font-weight:var(--typography-caption-font-weight);letter-spacing:var(--typography-caption-letter-spacing);color:var(--color-text-muted)}.error-message{margin:var(--space-grouped-minimal) 0 0 0;padding:0;font-family:var(--typography-caption-font-family);font-size:var(--typography-caption-font-size);line-height:var(--typography-caption-line-height);font-weight:var(--typography-caption-font-weight);letter-spacing:var(--typography-caption-letter-spacing);color:var(--color-feedback-error-text)}.trailing-icon-container{position:absolute;right:var(--space-inset-100);top:50%;transform:translateY(-50%);display:flex;align-items:center;justify-content:center;pointer-events:none;opacity:0;transition:opacity var(--motion-float-label-duration) var(--motion-float-label-easing);transition-delay:var(--motion-float-label-duration)}.input-wrapper.focused .trailing-icon-container{opacity:1;transition-delay:var(--motion-float-label-duration)}.input-wrapper.filled .trailing-icon-container{opacity:1;transition-delay:var(--motion-float-label-duration)}.input-wrapper:not(.focused):not(.filled) .trailing-icon-container{opacity:0;transition-delay:0ms}.trailing-icon{display:block}@media (prefers-reduced-motion:reduce){.input-element,.input-element:focus-visible,.input-label,.trailing-icon-container{transition:none}}";var J=class extends HTMLElement{constructor(){super();this.container=null;this.inputElement=null;this.labelElement=null;this.helperTextElement=null;this.errorMessageElement=null;this._focusColor="";this.onFocus=()=>{this.state=Mt(this.state),this.updateLabelPosition(),this.dispatchEvent(new CustomEvent("focus",{bubbles:!0,composed:!0}))};this.onBlur=()=>{this.state=Dt(this.state),this.updateLabelPosition(),this.dispatchEvent(new CustomEvent("blur",{bubbles:!0,composed:!0}))};this.onInput=e=>{let r=e.target.value;this.state=at(this.state,r),this.updateLabelPosition(),this.dispatchEvent(new CustomEvent("change",{detail:{value:r},bubbles:!0,composed:!0}))};this._shadowRoot=this.attachShadow({mode:"open"}),this._blendUtils=E(),this.state=Pt(this.getPropsFromAttributes())}get shadowRoot(){return this._shadowRoot}static get observedAttributes(){return["id","label","value","type","placeholder","helper-text","error-message","is-success","show-info-icon","read-only","required","max-length","autocomplete"]}connectedCallback(){document.readyState==="loading"?document.addEventListener("DOMContentLoaded",()=>{this._calculateBlendColorsWithRetry(),this.render(),this.attachEventListeners()},{once:!0}):(this._calculateBlendColorsWithRetry(),this.render(),this.attachEventListeners())}_calculateBlendColorsWithRetry(){try{this._calculateBlendColors()}catch(e){requestAnimationFrame(()=>{try{this._calculateBlendColors(),this.render()}catch(t){console.warn("InputTextBase: Could not calculate blend colors, using CSS fallbacks",t)}})}}_calculateBlendColors(){let t=getComputedStyle(document.documentElement).getPropertyValue("--color-action-primary").trim();if(!t)throw new Error("InputTextBase: Required token --color-action-primary is missing from CSS custom properties");this._focusColor=this._blendUtils.focusColor(t)}disconnectedCallback(){this.detachEventListeners()}attributeChangedCallback(e,t,r){if(t!==r){if(e==="value"){this.state=at(this.state,r||""),this.updateLabelPosition(),this.inputElement&&this.inputElement.value!==(r||"")&&(this.inputElement.value=r||"");return}else e==="error-message"?(this.state=lt(this.state,r||void 0,this.state.isSuccess),this.updateLabelPosition()):e==="is-success"&&(this.state=lt(this.state,this.state.hasError&&this.getAttribute("error-message")||void 0,r==="true"),this.updateLabelPosition());this.isConnected&&this.render()}}getPropsFromAttributes(){return{id:this.getAttribute("id")||"",label:this.getAttribute("label")||"",value:this.getAttribute("value")||"",onChange:()=>{},type:this.getAttribute("type")||"text",placeholder:this.getAttribute("placeholder")||void 0,helperText:this.getAttribute("helper-text")||void 0,errorMessage:this.getAttribute("error-message")||void 0,isSuccess:this.getAttribute("is-success")==="true",showInfoIcon:this.getAttribute("show-info-icon")==="true",readOnly:this.hasAttribute("read-only"),required:this.hasAttribute("required"),maxLength:this.hasAttribute("max-length")?parseInt(this.getAttribute("max-length"),10):void 0,autocomplete:this.getAttribute("autocomplete")||void 0}}render(){let e=this.getPropsFromAttributes(),t=st(this.state),r=ot(this.state);this.container||(this.container=document.createElement("div"),this.container.className="input-text-base");let s=Ot.size100,o="";r.showErrorIcon?o=D({name:"x",size:s,color:"color-error",className:"trailing-icon error-icon"}):r.showSuccessIcon?o=D({name:"check",size:s,color:"color-feedback-success-text",className:"trailing-icon success-icon"}):r.showInfoIcon&&(o=D({name:"info",size:s,color:"color-text-subtle",className:"trailing-icon info-icon"}));let a=`
|
|
45
45
|
--_itb-focus-color: ${this._focusColor};
|
|
46
46
|
`;this.container.innerHTML=`
|
|
47
47
|
<div class="input-wrapper ${this.state.hasError?"error":""} ${this.state.isSuccess?"success":""} ${this.state.isFocused?"focused":""} ${this.state.isFilled?"filled":""}" style="${a}">
|
|
@@ -76,7 +76,7 @@
|
|
|
76
76
|
${e.errorMessage}
|
|
77
77
|
</p>
|
|
78
78
|
`:""}
|
|
79
|
-
`;let l=document.createElement("style");l.textContent=Ft,this._shadowRoot.innerHTML="",this._shadowRoot.appendChild(l),this._shadowRoot.appendChild(this.container),this.inputElement=this._shadowRoot.querySelector(".input-element"),this.labelElement=this._shadowRoot.querySelector(".input-label"),this.helperTextElement=this._shadowRoot.querySelector(".helper-text"),this.errorMessageElement=this._shadowRoot.querySelector(".error-message")}attachEventListeners(){this.inputElement&&(this.inputElement.addEventListener("focus",this.onFocus),this.inputElement.addEventListener("blur",this.onBlur),this.inputElement.addEventListener("input",this.onInput))}detachEventListeners(){this.inputElement&&(this.inputElement.removeEventListener("focus",this.onFocus),this.inputElement.removeEventListener("blur",this.onBlur),this.inputElement.removeEventListener("input",this.onInput))}updateLabelPosition(){if(!this.labelElement||!this.container)return;st(this.state).isFloated?this.labelElement.classList.add("floated"):this.labelElement.classList.remove("floated");let t=this.container.querySelector(".input-wrapper");t&&(t.classList.toggle("focused",this.state.isFocused),t.classList.toggle("filled",this.state.isFilled),t.classList.toggle("error",this.state.hasError),t.classList.toggle("success",this.state.isSuccess)),this.updateIconVisibility()}updateIconVisibility(){if(!this.container)return;let e=ot(this.state),t=this.container.querySelector(".trailing-icon-container");if(!t)return;e.showErrorIcon||e.showSuccessIcon||e.showInfoIcon?t.style.opacity="1":t.style.opacity="0"}};customElements.get("input-text-base")||customElements.define("input-text-base",
|
|
79
|
+
`;let l=document.createElement("style");l.textContent=Ft,this._shadowRoot.innerHTML="",this._shadowRoot.appendChild(l),this._shadowRoot.appendChild(this.container),this.inputElement=this._shadowRoot.querySelector(".input-element"),this.labelElement=this._shadowRoot.querySelector(".input-label"),this.helperTextElement=this._shadowRoot.querySelector(".helper-text"),this.errorMessageElement=this._shadowRoot.querySelector(".error-message")}attachEventListeners(){this.inputElement&&(this.inputElement.addEventListener("focus",this.onFocus),this.inputElement.addEventListener("blur",this.onBlur),this.inputElement.addEventListener("input",this.onInput))}detachEventListeners(){this.inputElement&&(this.inputElement.removeEventListener("focus",this.onFocus),this.inputElement.removeEventListener("blur",this.onBlur),this.inputElement.removeEventListener("input",this.onInput))}updateLabelPosition(){if(!this.labelElement||!this.container)return;st(this.state).isFloated?this.labelElement.classList.add("floated"):this.labelElement.classList.remove("floated");let t=this.container.querySelector(".input-wrapper");t&&(t.classList.toggle("focused",this.state.isFocused),t.classList.toggle("filled",this.state.isFilled),t.classList.toggle("error",this.state.hasError),t.classList.toggle("success",this.state.isSuccess)),this.updateIconVisibility()}updateIconVisibility(){if(!this.container)return;let e=ot(this.state),t=this.container.querySelector(".trailing-icon-container");if(!t)return;e.showErrorIcon||e.showSuccessIcon||e.showInfoIcon?t.style.opacity="1":t.style.opacity="0"}};customElements.get("input-text-base")||customElements.define("input-text-base",J);var Ze="Please enter a valid email address",fr=/^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/;function _r(n){if(!n||n.trim()==="")return!0;let i=n.trim();if(!fr.test(i))return!1;let e=i.split("@")[0];return!(e.startsWith(".")||e.endsWith(".")||e.includes(".."))}function ct(n,i,e){return!n||n.trim()===""?{isValid:!0}:(i||_r)(n)?{isValid:!0}:{isValid:!1,errorMessage:e||Ze}}var Ee=class extends HTMLElement{constructor(){super();this._baseInput=null;this._hasBeenValidated=!1;this._isEmailValid=!0;this.onFocus=e=>{this.dispatchEvent(new CustomEvent("focus",{bubbles:!0,composed:!0}))};this.onBlur=e=>{let t=this.getAttribute("value")||"",r=this.getAttribute("invalid-email-message")||Ze,s=ct(t);if(this._hasBeenValidated=!0,this._isEmailValid=s.isValid,this._baseInput){let o=this.getAttribute("error-message")||"";!o&&!this._isEmailValid?this._baseInput.setAttribute("error-message",r):!o&&this._isEmailValid&&this._baseInput.removeAttribute("error-message")}this.dispatchEvent(new CustomEvent("blur",{bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("validate",{detail:{isValid:this._isEmailValid,errorMessage:s.errorMessage},bubbles:!0,composed:!0}))};this.onChange=e=>{var s;let r=((s=e.detail)==null?void 0:s.value)||"";this.setAttribute("value",r),this._hasBeenValidated=!1,this._isEmailValid=!0,this._baseInput&&this._baseInput.setAttribute("value",r),this.dispatchEvent(new CustomEvent("change",{detail:{value:r},bubbles:!0,composed:!0}))};this._shadowRoot=this.attachShadow({mode:"open"})}get shadowRoot(){return this._shadowRoot}static get observedAttributes(){return["id","label","value","placeholder","helper-text","error-message","is-success","show-info-icon","read-only","required","max-length","invalid-email-message"]}connectedCallback(){this.render(),this.attachEventListeners()}disconnectedCallback(){this.detachEventListeners()}attributeChangedCallback(e,t,r){if(t!==r){if(e==="value"){this._hasBeenValidated=!1,this._isEmailValid=!0;return}this.isConnected&&this.render()}}render(){let e=this.getAttribute("id")||"",t=this.getAttribute("label")||"",r=this.getAttribute("value")||"",s=this.getAttribute("placeholder")||"",o=this.getAttribute("helper-text")||"",a=this.getAttribute("error-message")||"",l=this.getAttribute("is-success")==="true",c=this.getAttribute("show-info-icon")==="true",d=this.hasAttribute("read-only"),h=this.hasAttribute("required"),u=this.getAttribute("max-length"),m=this.getAttribute("invalid-email-message")||Ze,g=a;!g&&this._hasBeenValidated&&!this._isEmailValid&&(g=m);let f=`
|
|
80
80
|
<input-text-base
|
|
81
81
|
id="${e}"
|
|
82
82
|
label="${t}"
|
|
@@ -239,7 +239,7 @@
|
|
|
239
239
|
<icon-base name="${e}" size="${a}" color="inherit"></icon-base>
|
|
240
240
|
</span>
|
|
241
241
|
</button>
|
|
242
|
-
`,this._button=this._shadowRoot.querySelector("button"),this._iconContainer=this._shadowRoot.querySelector(".button-icon__icon"),this._iconEl=((h=this._iconContainer)==null?void 0:h.querySelector("icon-base"))||null}_updateDOM(){if(!this._button||!this._iconEl)return;let e=this.icon,t=this.ariaLabel,r=this.size,s=this.buttonVariant,o=this.testID,a=Zt(r),l=["button-icon",`button-icon--${r}`,`button-icon--${s}`].filter(Boolean).join(" ");this._button.className=l,this._button.setAttribute("aria-label",t),o?this._button.setAttribute("data-testid",o):this._button.removeAttribute("data-testid"),this._button.style.setProperty("--_bi-hover-bg",this._hoverColor),this._button.style.setProperty("--_bi-pressed-bg",this._pressedColor),this._iconEl.setAttribute("name",e),this._iconEl.setAttribute("size",String(a))}_attachEventListeners(){this._button&&(this._button.addEventListener("click",this._handleClick),this._button.addEventListener("keydown",this._handleKeyDown))}_detachEventListeners(){this._button&&(this._button.removeEventListener("click",this._handleClick),this._button.removeEventListener("keydown",this._handleKeyDown))}};customElements.get("button-icon")||customElements.define("button-icon",Re);var U={none:"","050":"space.inset.050",100:"space.inset.100",150:"space.inset.150",200:"space.inset.200",300:"space.inset.300",400:"space.inset.400"},Yt={none:"",default:"border.border.default",emphasis:"border.border.emphasis",heavy:"border.border.heavy"},Xt={none:"",tight:"radius-050",normal:"radius-100",loose:"radius-200"},Jt={web:{container:"zIndex.container",navigation:"zIndex.navigation",dropdown:"zIndex.dropdown",modal:"zIndex.modal",toast:"zIndex.toast",tooltip:"zIndex.tooltip"},ios:{container:"zIndex.container",navigation:"zIndex.navigation",dropdown:"zIndex.dropdown",modal:"zIndex.modal",toast:"zIndex.toast",tooltip:"zIndex.tooltip"},android:{container:"elevation.container",navigation:"elevation.navigation",dropdown:"elevation.dropdown",modal:"elevation.modal",toast:"elevation.toast",tooltip:"elevation.tooltip"}};var Qt="color.border";function R(n){return`var(--${n.replace(/\./g,"-")})`}function Cr(n){if(!n||n==="none")return"";let i=U[n];return i?`padding: ${R(i)}`:""}function Sr(n){if(!n||n==="none")return"";let i=U[n];return i?`padding-block: ${R(i)}`:""}function Er(n){if(!n||n==="none")return"";let i=U[n];return i?`padding-inline: ${R(i)}`:""}function wr(n){if(!n||n==="none")return"";let i=U[n];return i?`padding-block-start: ${R(i)}`:""}function Ar(n){if(!n||n==="none")return"";let i=U[n];return i?`padding-block-end: ${R(i)}`:""}function Tr(n){if(!n||n==="none")return"";let i=U[n];return i?`padding-inline-start: ${R(i)}`:""}function Ir(n){if(!n||n==="none")return"";let i=U[n];return i?`padding-inline-end: ${R(i)}`:""}function zr(n,i){if(!n||n==="none")return"";let e=Yt[n];if(!e)return"";let t=R(e),r=R(i||Qt);return`border: ${t} solid ${r}`}function Rr(n){if(!n||n==="none")return"";let i=Xt[n];return i?`border-radius: ${R(i)}`:""}function Br(n){return n?`background: ${R(n)}`:""}function Lr(n){return n?`box-shadow: ${R(n)}`:""}function Vr(n){return n?`opacity: ${R(n)}`:"opacity: var(--opacity-subtle)"}function $r(n){if(!n)return"";let i=Jt.web[n];return i?`z-index: ${R(i)}`:""}function ei(n){var f,b,x,C,_,S,k,T,w,I,
|
|
242
|
+
`,this._button=this._shadowRoot.querySelector("button"),this._iconContainer=this._shadowRoot.querySelector(".button-icon__icon"),this._iconEl=((h=this._iconContainer)==null?void 0:h.querySelector("icon-base"))||null}_updateDOM(){if(!this._button||!this._iconEl)return;let e=this.icon,t=this.ariaLabel,r=this.size,s=this.buttonVariant,o=this.testID,a=Zt(r),l=["button-icon",`button-icon--${r}`,`button-icon--${s}`].filter(Boolean).join(" ");this._button.className=l,this._button.setAttribute("aria-label",t),o?this._button.setAttribute("data-testid",o):this._button.removeAttribute("data-testid"),this._button.style.setProperty("--_bi-hover-bg",this._hoverColor),this._button.style.setProperty("--_bi-pressed-bg",this._pressedColor),this._iconEl.setAttribute("name",e),this._iconEl.setAttribute("size",String(a))}_attachEventListeners(){this._button&&(this._button.addEventListener("click",this._handleClick),this._button.addEventListener("keydown",this._handleKeyDown))}_detachEventListeners(){this._button&&(this._button.removeEventListener("click",this._handleClick),this._button.removeEventListener("keydown",this._handleKeyDown))}};customElements.get("button-icon")||customElements.define("button-icon",Re);var U={none:"","050":"space.inset.050",100:"space.inset.100",150:"space.inset.150",200:"space.inset.200",300:"space.inset.300",400:"space.inset.400"},Yt={none:"",default:"border.border.default",emphasis:"border.border.emphasis",heavy:"border.border.heavy"},Xt={none:"",tight:"radius-050",normal:"radius-100",loose:"radius-200"},Jt={web:{container:"zIndex.container",navigation:"zIndex.navigation",dropdown:"zIndex.dropdown",modal:"zIndex.modal",toast:"zIndex.toast",tooltip:"zIndex.tooltip"},ios:{container:"zIndex.container",navigation:"zIndex.navigation",dropdown:"zIndex.dropdown",modal:"zIndex.modal",toast:"zIndex.toast",tooltip:"zIndex.tooltip"},android:{container:"elevation.container",navigation:"elevation.navigation",dropdown:"elevation.dropdown",modal:"elevation.modal",toast:"elevation.toast",tooltip:"elevation.tooltip"}};var Qt="color.border";function R(n){return`var(--${n.replace(/\./g,"-")})`}function Cr(n){if(!n||n==="none")return"";let i=U[n];return i?`padding: ${R(i)}`:""}function Sr(n){if(!n||n==="none")return"";let i=U[n];return i?`padding-block: ${R(i)}`:""}function Er(n){if(!n||n==="none")return"";let i=U[n];return i?`padding-inline: ${R(i)}`:""}function wr(n){if(!n||n==="none")return"";let i=U[n];return i?`padding-block-start: ${R(i)}`:""}function Ar(n){if(!n||n==="none")return"";let i=U[n];return i?`padding-block-end: ${R(i)}`:""}function Tr(n){if(!n||n==="none")return"";let i=U[n];return i?`padding-inline-start: ${R(i)}`:""}function Ir(n){if(!n||n==="none")return"";let i=U[n];return i?`padding-inline-end: ${R(i)}`:""}function zr(n,i){if(!n||n==="none")return"";let e=Yt[n];if(!e)return"";let t=R(e),r=R(i||Qt);return`border: ${t} solid ${r}`}function Rr(n){if(!n||n==="none")return"";let i=Xt[n];return i?`border-radius: ${R(i)}`:""}function Br(n){return n?`background: ${R(n)}`:""}function Lr(n){return n?`box-shadow: ${R(n)}`:""}function Vr(n){return n?`opacity: ${R(n)}`:"opacity: var(--opacity-subtle)"}function $r(n){if(!n)return"";let i=Jt.web[n];return i?`z-index: ${R(i)}`:""}function ei(n){var f,b,x,C,_,S,k,T,w,I,Z,H,$,M;let i=[],e=Cr((f=n.padding)!=null?f:null);e&&i.push(e);let t=Sr((b=n.paddingVertical)!=null?b:null);t&&i.push(t);let r=Er((x=n.paddingHorizontal)!=null?x:null);r&&i.push(r);let s=wr((C=n.paddingBlockStart)!=null?C:null);s&&i.push(s);let o=Ar((_=n.paddingBlockEnd)!=null?_:null);o&&i.push(o);let a=Tr((S=n.paddingInlineStart)!=null?S:null);a&&i.push(a);let l=Ir((k=n.paddingInlineEnd)!=null?k:null);l&&i.push(l);let c=Br((T=n.background)!=null?T:null);c&&i.push(c);let d=Lr((w=n.shadow)!=null?w:null);d&&i.push(d);let h=zr((I=n.border)!=null?I:null,(Z=n.borderColor)!=null?Z:null);h&&i.push(h);let u=Rr((H=n.borderRadius)!=null?H:null);u&&i.push(u);let m=Vr(($=n.opacity)!=null?$:null);m&&i.push(m);let g=$r((M=n.layering)!=null?M:null);return g&&i.push(g),i.join(`;
|
|
243
243
|
`)}var Pr=`
|
|
244
244
|
:host {
|
|
245
245
|
display: block;
|
|
@@ -302,7 +302,7 @@
|
|
|
302
302
|
<${b} class="${k.join(" ")}" ${S} style="${T}">
|
|
303
303
|
<slot></slot>
|
|
304
304
|
</${b}>
|
|
305
|
-
`}buildStyles(e){return ei(e)}};customElements.get("container-base")||customElements.define("container-base",q);var ti={rest:{background:"var(--color-structure-canvas)",borderWidth:"var(--border-default)",borderColor:"transparent",labelColor:"var(--color-text-default)",iconColor:"var(--color-text-default)",checkmarkVisible:!1,cssClass:"vertical-list-item--rest"},selected:{background:"var(--color-feedback-select-background-rest)",borderWidth:"var(--border-emphasis)",borderColor:"var(--color-feedback-select-text-rest)",labelColor:"var(--color-feedback-select-text-rest)",iconColor:"var(--color-feedback-select-text-rest)",checkmarkVisible:!0,cssClass:"vertical-list-item--selected"},notSelected:{background:"var(--color-feedback-select-background-default)",borderWidth:"var(--border-default)",borderColor:"transparent",labelColor:"var(--color-feedback-select-text-default)",iconColor:"var(--color-feedback-select-text-default)",checkmarkVisible:!1,cssClass:"vertical-list-item--not-selected"},checked:{background:"var(--color-feedback-select-background-rest)",borderWidth:"var(--border-default)",borderColor:"transparent",labelColor:"var(--color-feedback-select-text-rest)",iconColor:"var(--color-feedback-select-text-rest)",checkmarkVisible:!0,cssClass:"vertical-list-item--checked"},unchecked:{background:"var(--color-structure-canvas)",borderWidth:"var(--border-default)",borderColor:"transparent",labelColor:"var(--color-text-default)",iconColor:"var(--color-text-default)",checkmarkVisible:!1,cssClass:"vertical-list-item--unchecked"}};function Mr(n){let i=ti[n];if(!i)throw new Error(`Button-VerticalList-Item: Invalid visual state "${n}". Valid states are: ${Object.keys(ti).join(", ")}`);return i}function Dr(n){return n==="rest"||n==="selected"||n==="notSelected"}function Nr(n){return n==="checked"||n==="unchecked"}function ii(n){return n==="selected"}function Hr(n,i){return Dr(i)?P(V({},n),{background:"var(--color-feedback-error-background)",borderWidth:"var(--border-emphasis)",borderColor:"var(--color-feedback-error-text)",labelColor:"var(--color-feedback-error-text)",iconColor:"var(--color-feedback-error-text)",cssClass:`${n.cssClass} vertical-list-item--error`}):Nr(i)?P(V({},n),{labelColor:"var(--color-feedback-error-text)",iconColor:"var(--color-feedback-error-text)",cssClass:`${n.cssClass} vertical-list-item--error`}):n}function ri(n,i=!1){let e=Mr(n);return i?Hr(e,n):e}var gt="@3fn/dp:tokenContract";function Or(n){return"reference"in n}function G(n){let{component:i,family:e,tokens:t}=n;if(!i||i.trim()==="")throw new Error("Component name is required for defineComponentTokens()");if(!e||e.trim()==="")throw new Error("Token family is required for defineComponentTokens()");if(!t||Object.keys(t).length===0)throw new Error("At least one token definition is required for defineComponentTokens()");let r={},s=[];for(let[o,a]of Object.entries(t)){let l=`${i.toLowerCase()}.${o}`;if(Or(a)){let c=a.reference,d=c.baseValue;r[o]=d,s.push({name:l,component:i,family:e,value:d,primitiveReference:c.name,reasoning:a.reasoning})}else r[o]=a.value,s.push({name:l,component:i,family:e,value:a.value,reasoning:a.reasoning})}return Object.prototype.hasOwnProperty.call(r,gt)||Object.defineProperty(r,gt,{value:s,enumerable:!1,configurable:!0,writable:!1}),r}var Me=class{constructor(){this.defaultWebBaseFontSize=16;this.defaultPrecision=2}convertToAllPlatforms(i,e,t={}){let r=this.convertToiOS(i,e,t),s=this.convertToAndroid(i,e,t),o=this.convertToWeb(i,e,t),a=this.validateMathematicalConsistency(i,r,s,o,t);return{ios:r,android:s,web:o,mathematicallyConsistent:a.consistent,reasoning:a.reasoning}}convertToiOS(i,e,t={}){var o;let r=(o=t.precision)!=null?o:this.defaultPrecision;return{value:this.roundToPrecision(i,r),unit:"pt",token:e}}convertToAndroid(i,e,t={}){var a;let r=(a=t.precision)!=null?a:this.defaultPrecision,s=this.roundToPrecision(i,r),o=this.isTypographyToken(e,t.category)?"sp":"dp";return{value:s,unit:o,token:e}}convertToWeb(i,e,t={}){var a,l;let r=(a=t.precision)!=null?a:this.defaultPrecision,s=(l=t.webBaseFontSize)!=null?l:this.defaultWebBaseFontSize;if(this.isTypographyToken(e,t.category)){let c=i/s;return{value:this.roundToPrecision(c,r),unit:"rem",token:e}}return{value:this.roundToPrecision(i,r),unit:"px",token:e}}validateMathematicalConsistency(i,e,t,r,s){var u;let o=(u=s.webBaseFontSize)!=null?u:this.defaultWebBaseFontSize,a=e.value===i,l=t.value===i,c=!1;if(r.unit==="px")c=r.value===i;else if(r.unit==="rem"){let m=i/o;c=Math.abs(r.value-m)<.001}if(a&&l&&c)return{consistent:!0,reasoning:`All platforms maintain mathematical consistency: baseValue ${i} \u2192 iOS ${e.value}${e.unit}, Android ${t.value}${t.unit}, Web ${r.value}${r.unit}`};let h=[];if(a||h.push(`iOS: expected ${i}pt, got ${e.value}pt`),l||h.push(`Android: expected ${i}${t.unit}, got ${t.value}${t.unit}`),!c)if(r.unit==="rem"){let m=i/o;h.push(`Web: expected ${m}rem, got ${r.value}rem`)}else h.push(`Web: expected ${i}px, got ${r.value}px`);return{consistent:!1,reasoning:`Mathematical inconsistency detected: ${h.join("; ")}`}}isTypographyToken(i,e){return e==="typography"?!0:[/font/i,/text/i,/typography/i,/lineHeight/i,/letterSpacing/i].some(r=>r.test(i))}roundToPrecision(i,e){let t=Math.pow(10,e);return Math.round(i*t)/t}applyScaleWithRounding(i,e){let t=i*e,r=Math.round(t),s=Math.abs(t-r);return s>.5&&console.warn(`Rounding precision loss: ${i}px \xD7 ${e} = ${t}px \u2192 ${r}px (loss: ${s.toFixed(2)}px)`),r}convertToPlatform(i,e,t,r={}){switch(t){case"ios":return this.convertToiOS(i,e,r);case"android":return this.convertToAndroid(i,e,r);case"web":return this.convertToWeb(i,e,r);default:throw new Error(`Unknown platform: ${t}`)}}},Fr=new Me;var N={space075:{value:6,derivation:"space100 \xD7 0.75"},space125:{value:10,derivation:"space100 \xD7 1.25"},space250:{value:20,derivation:"space100 \xD7 2.5"}},v=8;function B(n){return{web:{value:n,unit:"px"},ios:{value:n,unit:"pt"},android:{value:n,unit:"dp"}}}var mt={space000:{name:"space000",category:"spacing",baseValue:0,familyBaseValue:v,description:"Zero spacing - explicit no spacing value",mathematicalRelationship:"base \xD7 0 = 8 \xD7 0 = 0",baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(0)},space025:{name:"space025",category:"spacing",baseValue:v*.25,familyBaseValue:v,description:"Extra tight spacing - 0.25x base value",mathematicalRelationship:"base \xD7 0.25 = 8 \xD7 0.25 = 2",baselineGridAlignment:!1,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*.25)},space050:{name:"space050",category:"spacing",baseValue:v*.5,familyBaseValue:v,description:"Tight spacing - 0.5x base value",mathematicalRelationship:"base \xD7 0.5 = 8 \xD7 0.5 = 4",baselineGridAlignment:!1,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*.5)},space075:{name:"space075",category:"spacing",baseValue:N.space075.value,familyBaseValue:v,description:"Strategic flexibility spacing - 0.75x base value",mathematicalRelationship:N.space075.derivation,baselineGridAlignment:!1,isStrategicFlexibility:!0,isPrecisionTargeted:!1,platforms:B(N.space075.value)},space100:{name:"space100",category:"spacing",baseValue:v,familyBaseValue:v,description:"Base spacing - 1x base value",mathematicalRelationship:"base \xD7 1 = 8 \xD7 1 = 8",baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v)},space125:{name:"space125",category:"spacing",baseValue:N.space125.value,familyBaseValue:v,description:"Strategic flexibility spacing - 1.25x base value",mathematicalRelationship:N.space125.derivation,baselineGridAlignment:!1,isStrategicFlexibility:!0,isPrecisionTargeted:!1,platforms:B(N.space125.value)},space150:{name:"space150",category:"spacing",baseValue:v*1.5,familyBaseValue:v,description:"Loose spacing - 1.5x base value",mathematicalRelationship:"base \xD7 1.5 = 8 \xD7 1.5 = 12",baselineGridAlignment:!1,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*1.5)},space200:{name:"space200",category:"spacing",baseValue:v*2,familyBaseValue:v,description:"Wide spacing - 2x base value",mathematicalRelationship:"base \xD7 2 = 8 \xD7 2 = 16",baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*2)},space250:{name:"space250",category:"spacing",baseValue:N.space250.value,familyBaseValue:v,description:"Strategic flexibility spacing - 2.5x base value",mathematicalRelationship:N.space250.derivation,baselineGridAlignment:!1,isStrategicFlexibility:!0,isPrecisionTargeted:!1,platforms:B(N.space250.value)},space300:{name:"space300",category:"spacing",baseValue:v*3,familyBaseValue:v,description:"Extra wide spacing - 3x base value",mathematicalRelationship:"base \xD7 3 = 8 \xD7 3 = 24",baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*3)},space400:{name:"space400",category:"spacing",baseValue:v*4,familyBaseValue:v,description:"Large spacing - 4x base value",mathematicalRelationship:"base \xD7 4 = 8 \xD7 4 = 32",baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*4)},space500:{name:"space500",category:"spacing",baseValue:v*5,familyBaseValue:v,description:"Extra large spacing - 5x base value",mathematicalRelationship:"base \xD7 5 = 8 \xD7 5 = 40",baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*5)},space600:{name:"space600",category:"spacing",baseValue:v*6,familyBaseValue:v,description:"Huge spacing - 6x base value",mathematicalRelationship:"base \xD7 6 = 8 \xD7 6 = 48",baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*6)},space700:{name:"space700",category:"spacing",baseValue:v*7,familyBaseValue:v,description:"Extra huge spacing - 7x base value",mathematicalRelationship:"base \xD7 7 = 8 \xD7 7 = 56",baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*7)},space800:{name:"space800",category:"spacing",baseValue:v*8,familyBaseValue:v,description:"Maximum spacing - 8x base value",mathematicalRelationship:"base \xD7 8 = 8 \xD7 8 = 64",baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*8)}},Yo=Object.keys(mt);var Gr=G({component:"VerticalListItem",family:"spacing",tokens:{"paddingBlock.rest":{value:v*1.375,reasoning:"Block padding at rest state (1px border). 11px padding + 1px border = 12px per side, achieving 48px total with 24px content. Uses TokenWithValue pattern as no primitive token exists for 11px."},"paddingBlock.selected":{reference:mt.space125,reasoning:"Block padding when selected (2px border). 10px padding + 2px border = 12px per side, maintaining 48px total with 24px content. References space125 strategic flexibility token."}}});function ni(n){return Gr[`paddingBlock.${n}`]}var si=":host{display:block;width:100%;--_vlbi-focus-offset:var(--accessibility-focus-offset);--_vlbi-focus-width:var(--accessibility-focus-width);--_vlbi-focus-color:var(--accessibility-focus-color);--_vlbi-min-height:var(--tap-area-recommended);--_vlbi-radius:var(--radius-normal);--_vlbi-padding-inline:var(--space-inset-200);--_vlbi-gap:var(--space-grouped-loose);--_vlbi-label-font-size:var(--typography-button-md-font-size);--_vlbi-label-font-weight:var(--typography-button-md-font-weight);--_vlbi-label-line-height:var(--typography-button-md-line-height);--_vlbi-description-font-size:var(--typography-body-sm-font-size);--_vlbi-description-font-weight:var(--typography-body-sm-font-weight);--_vlbi-description-line-height:var(--typography-body-sm-line-height);--_vlbi-description-color:var(--color-text-muted);--_vlbi-transition-duration:var(--motion-selection-transition-duration);--_vlbi-transition-easing:var(--motion-selection-transition-easing)}.vertical-list-item{appearance:none;margin:0;font:inherit;display:flex;align-items:center;gap:var(--_vlbi-gap);width:100%;min-height:var(--_vlbi-min-height);padding-block:var(--_vlbi-padding-block);padding-inline:var(--_vlbi-padding-inline);background:var(--_vlbi-background);border:var(--_vlbi-border-width) solid var(--_vlbi-border-color);border-radius:var(--_vlbi-radius);text-align:start;cursor:pointer;transition:background var(--_vlbi-transition-duration) var(--_vlbi-transition-easing),background-color var(--_vlbi-transition-duration) var(--_vlbi-transition-easing),border-color var(--_vlbi-transition-duration) var(--_vlbi-transition-easing),border-width var(--_vlbi-transition-duration) var(--_vlbi-transition-easing),padding var(--_vlbi-transition-duration) var(--_vlbi-transition-easing),color var(--_vlbi-transition-duration) var(--_vlbi-transition-easing);outline:none}.vertical-list-item:hover{background-color:var(--_vlbi-hover-bg)}.vertical-list-item:active{background-color:var(--_vlbi-pressed-bg)}.vertical-list-item:focus-visible{outline:var(--_vlbi-focus-width) solid var(--_vlbi-focus-color);outline-offset:var(--_vlbi-focus-offset)}.vertical-list-item:focus:not(:focus-visible){outline:none}.vertical-list-item__content{display:flex;flex-direction:column;flex:1;min-width:0}.vertical-list-item__label{color:var(--_vlbi-label-color);font-size:var(--_vlbi-label-font-size);font-weight:var(--_vlbi-label-font-weight);line-height:var(--_vlbi-label-line-height);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.vertical-list-item__description{color:var(--_vlbi-description-color);font-size:var(--_vlbi-description-font-size);font-weight:var(--_vlbi-description-font-weight);line-height:var(--_vlbi-description-line-height)}.vertical-list-item__leading-icon{flex-shrink:0;display:inline-flex;align-items:center;justify-content:center}.vertical-list-item__checkmark{flex-shrink:0;color:var(--_vlbi-icon-color);display:inline-flex;align-items:center;justify-content:center;transition:opacity var(--_vlbi-transition-duration) var(--_vlbi-transition-easing),visibility var(--_vlbi-transition-duration) var(--_vlbi-transition-easing)}.vertical-list-item__checkmark--fade{opacity:inherit}.vertical-list-item__checkmark--instant.vertical-list-item__checkmark--hidden{transition:none}.vertical-list-item__checkmark--hidden{opacity:0;visibility:hidden}.vertical-list-item__checkmark--visible{opacity:1;visibility:visible}@media (prefers-contrast:high){.vertical-list-item{border-width:2px !important}.vertical-list-item:focus-visible{outline-width:4px}}@media (prefers-reduced-motion:reduce){.vertical-list-item,.vertical-list-item__checkmark--fade{transition:none}}@media print{.vertical-list-item{background-color:transparent !important;border:1px solid currentColor !important;filter:none !important}}";var Wr=["--color-structure-canvas","--color-text-default","--color-text-muted","--color-feedback-select-text-rest","--color-feedback-select-background-rest","--color-feedback-select-text-default","--color-feedback-select-background-default","--color-feedback-error-text","--color-feedback-error-background","--border-default","--border-emphasis","--radius-normal","--space-inset-200","--space-grouped-loose","--tap-area-recommended","--accessibility-focus-width","--accessibility-focus-offset","--accessibility-focus-color","--motion-selection-transition-duration","--motion-selection-transition-easing"];function jr(){let n=getComputedStyle(document.documentElement),i=[];for(let e of Wr)n.getPropertyValue(e).trim()||i.push(e);if(i.length>0)throw new Error(`Button-VerticalList-Item: Missing required CSS variables: ${i.join(", ")}. Ensure Rosetta-generated tokens are loaded before using this component.`)}function Kr(n,i=!1){let e=n==="rest"||n==="selected"||n==="notSelected",r=ii(n)||i&&e?"selected":"rest";return`${ni(r)}px`}function oi(n){let i=n.match(/var\(([^)]+)\)/);if(!i)return n;let e=i[1].trim();return getComputedStyle(document.documentElement).getPropertyValue(e).trim()||n}var ee=class extends HTMLElement{constructor(){super();this._tokensValidated=!1;this._domCreated=!1;this._button=null;this._labelEl=null;this._descriptionEl=null;this._leadingIconContainer=null;this._leadingIconEl=null;this._checkmarkContainer=null;this._checkmarkIconEl=null;this._hoverColor="";this._pressedColor="";this._handleClick=()=>{this._onClick&&this._onClick()};this._handleFocus=()=>{this._onFocus&&this._onFocus(),this.dispatchEvent(new CustomEvent("focus",{bubbles:!0,composed:!0}))};this._handleBlur=()=>{this._onBlur&&this._onBlur(),this.dispatchEvent(new CustomEvent("blur",{bubbles:!0,composed:!0}))};this._handleKeyDown=e=>{(e.key==="Enter"||e.key===" ")&&(e.preventDefault(),this._handleClick())};this._shadowRoot=this.attachShadow({mode:"open",delegatesFocus:!0}),this._blendUtils=E()}static get observedAttributes(){return["label","description","leading-icon","visual-state","error","checkmark-transition","transition-delay","test-id","role","aria-checked","disabled"]}connectedCallback(){document.readyState==="loading"?document.addEventListener("DOMContentLoaded",()=>{this._validateAndRender()},{once:!0}):this._validateAndRender()}_validateAndRender(){this._tokensValidated||(jr(),this._tokensValidated=!0),this._calculateBlendColorsWithRetry(),this._render()}_calculateBlendColorsWithRetry(){try{this._calculateBlendColors()}catch(e){requestAnimationFrame(()=>{try{this._calculateBlendColors(),this._render()}catch(t){console.warn("ButtonVerticalListItem: Could not calculate blend colors, using CSS fallbacks",t)}})}}_calculateBlendColors(){let t=getComputedStyle(document.documentElement).getPropertyValue("--color-structure-canvas").trim();if(!t)throw new Error("Button-VerticalList-Item: Required token --color-structure-canvas is missing from CSS custom properties");this._hoverColor=this._blendUtils.hoverColor(t),this._pressedColor=this._blendUtils.pressedColor(t)}disconnectedCallback(){this._detachEventListeners()}attributeChangedCallback(e,t,r){if(e==="disabled")throw new Error('Button-VerticalList-Item: The "disabled" attribute is not supported. Per accessibility standards, unavailable options should be hidden rather than disabled. Remove the disabled attribute and hide the component instead.');t!==r&&this.isConnected&&this._tokensValidated&&this._domCreated&&this._updateDOM()}get label(){return this.getAttribute("label")||""}set label(e){this.setAttribute("label",e)}get description(){return this.getAttribute("description")||void 0}set description(e){e?this.setAttribute("description",e):this.removeAttribute("description")}get leadingIcon(){return this.getAttribute("leading-icon")}set leadingIcon(e){e?this.setAttribute("leading-icon",e):this.removeAttribute("leading-icon")}get visualState(){let e=this.getAttribute("visual-state");return e&&["rest","selected","notSelected","checked","unchecked"].includes(e)?e:"rest"}set visualState(e){this.setAttribute("visual-state",e)}get error(){return this.getAttribute("error")==="true"}set error(e){this.setAttribute("error",e.toString())}get checkmarkTransition(){return this.getAttribute("checkmark-transition")==="instant"?"instant":"fade"}set checkmarkTransition(e){this.setAttribute("checkmark-transition",e)}get transitionDelay(){let e=this.getAttribute("transition-delay");return e?parseInt(e,10):0}set transitionDelay(e){this.setAttribute("transition-delay",e.toString())}get testID(){return this.getAttribute("test-id")||void 0}set testID(e){e?this.setAttribute("test-id",e):this.removeAttribute("test-id")}get disabled(){return!1}set disabled(e){if(e)throw new Error('Button-VerticalList-Item: The "disabled" property is not supported. Per accessibility standards, unavailable options should be hidden rather than disabled. Set disabled to false or hide the component instead.')}get itemRole(){let e=this.getAttribute("role");return e==="radio"||e==="checkbox"?e:"button"}set itemRole(e){this.setAttribute("role",e)}get itemAriaChecked(){let e=this.getAttribute("aria-checked");if(e==="true")return!0;if(e==="false")return!1}set itemAriaChecked(e){e===void 0?this.removeAttribute("aria-checked"):this.setAttribute("aria-checked",e.toString())}set onClick(e){this._onClick=e}get onClick(){return this._onClick}set onFocus(e){this._onFocus=e}get onFocus(){return this._onFocus}set onBlur(e){this._onBlur=e}get onBlur(){return this._onBlur}_render(){this._domCreated?this._updateDOM():(this._createDOM(),this._domCreated=!0,this._attachEventListeners())}_createDOM(){var t,r;let e=A.size100;this._shadowRoot.innerHTML=`
|
|
305
|
+
`}buildStyles(e){return ei(e)}};customElements.get("container-base")||customElements.define("container-base",q);var ti={rest:{background:"var(--color-structure-canvas)",borderWidth:"var(--border-default)",borderColor:"transparent",labelColor:"var(--color-text-default)",iconColor:"var(--color-text-default)",checkmarkVisible:!1,cssClass:"vertical-list-item--rest"},selected:{background:"var(--color-feedback-select-background-rest)",borderWidth:"var(--border-emphasis)",borderColor:"var(--color-feedback-select-text-rest)",labelColor:"var(--color-feedback-select-text-rest)",iconColor:"var(--color-feedback-select-text-rest)",checkmarkVisible:!0,cssClass:"vertical-list-item--selected"},notSelected:{background:"var(--color-feedback-select-background-default)",borderWidth:"var(--border-default)",borderColor:"transparent",labelColor:"var(--color-feedback-select-text-default)",iconColor:"var(--color-feedback-select-text-default)",checkmarkVisible:!1,cssClass:"vertical-list-item--not-selected"},checked:{background:"var(--color-feedback-select-background-rest)",borderWidth:"var(--border-default)",borderColor:"transparent",labelColor:"var(--color-feedback-select-text-rest)",iconColor:"var(--color-feedback-select-text-rest)",checkmarkVisible:!0,cssClass:"vertical-list-item--checked"},unchecked:{background:"var(--color-structure-canvas)",borderWidth:"var(--border-default)",borderColor:"transparent",labelColor:"var(--color-text-default)",iconColor:"var(--color-text-default)",checkmarkVisible:!1,cssClass:"vertical-list-item--unchecked"}};function Mr(n){let i=ti[n];if(!i)throw new Error(`Button-VerticalList-Item: Invalid visual state "${n}". Valid states are: ${Object.keys(ti).join(", ")}`);return i}function Dr(n){return n==="rest"||n==="selected"||n==="notSelected"}function Nr(n){return n==="checked"||n==="unchecked"}function ii(n){return n==="selected"}function Hr(n,i){return Dr(i)?P(V({},n),{background:"var(--color-feedback-error-background)",borderWidth:"var(--border-emphasis)",borderColor:"var(--color-feedback-error-text)",labelColor:"var(--color-feedback-error-text)",iconColor:"var(--color-feedback-error-text)",cssClass:`${n.cssClass} vertical-list-item--error`}):Nr(i)?P(V({},n),{labelColor:"var(--color-feedback-error-text)",iconColor:"var(--color-feedback-error-text)",cssClass:`${n.cssClass} vertical-list-item--error`}):n}function ri(n,i=!1){let e=Mr(n);return i?Hr(e,n):e}var gt="@3fn/dp:tokenContract";function Or(n){return"reference"in n}function Q(n){let{component:i,family:e,tokens:t}=n;if(!i||i.trim()==="")throw new Error("Component name is required for defineComponentTokens()");if(!e||e.trim()==="")throw new Error("Token family is required for defineComponentTokens()");if(!t||Object.keys(t).length===0)throw new Error("At least one token definition is required for defineComponentTokens()");let r={},s=[];for(let[o,a]of Object.entries(t)){let l=`${i.toLowerCase()}.${o}`;if(Or(a)){let c=a.reference;if(typeof c.category=="string"&&c.category!==e)throw new Error(`Token family mismatch in defineComponentTokens() for component '${i}': token '${o}' is declared in a '${e}' family call but references primitive '${c.name}' from the '${c.category}' family. Every token in a call is stamped with that call's family, which drives platform output (e.g. the generated '${e.charAt(0).toUpperCase()+e.slice(1)}Tokens' class reference), so this would emit a non-existent platform member. Fix: move '${o}' into a separate defineComponentTokens() call with family: '${c.category}', or use the value path if no token-chain relationship is intended.`);let d=c.baseValue;r[o]=d,s.push({name:l,component:i,family:e,value:d,primitiveReference:c.name,reasoning:a.reasoning})}else r[o]=a.value,s.push({name:l,component:i,family:e,value:a.value,reasoning:a.reasoning})}return Object.prototype.hasOwnProperty.call(r,gt)||Object.defineProperty(r,gt,{value:s,enumerable:!1,configurable:!0,writable:!1}),r}var Me=class{constructor(){this.defaultWebBaseFontSize=16;this.defaultPrecision=2}convertToAllPlatforms(i,e,t={}){let r=this.convertToiOS(i,e,t),s=this.convertToAndroid(i,e,t),o=this.convertToWeb(i,e,t),a=this.validateMathematicalConsistency(i,r,s,o,t);return{ios:r,android:s,web:o,mathematicallyConsistent:a.consistent,reasoning:a.reasoning}}convertToiOS(i,e,t={}){var o;let r=(o=t.precision)!=null?o:this.defaultPrecision;return{value:this.roundToPrecision(i,r),unit:"pt",token:e}}convertToAndroid(i,e,t={}){var a;let r=(a=t.precision)!=null?a:this.defaultPrecision,s=this.roundToPrecision(i,r),o=this.isTypographyToken(e,t.category)?"sp":"dp";return{value:s,unit:o,token:e}}convertToWeb(i,e,t={}){var a,l;let r=(a=t.precision)!=null?a:this.defaultPrecision,s=(l=t.webBaseFontSize)!=null?l:this.defaultWebBaseFontSize;if(this.isTypographyToken(e,t.category)){let c=i/s;return{value:this.roundToPrecision(c,r),unit:"rem",token:e}}return{value:this.roundToPrecision(i,r),unit:"px",token:e}}validateMathematicalConsistency(i,e,t,r,s){var u;let o=(u=s.webBaseFontSize)!=null?u:this.defaultWebBaseFontSize,a=e.value===i,l=t.value===i,c=!1;if(r.unit==="px")c=r.value===i;else if(r.unit==="rem"){let m=i/o;c=Math.abs(r.value-m)<.001}if(a&&l&&c)return{consistent:!0,reasoning:`All platforms maintain mathematical consistency: baseValue ${i} \u2192 iOS ${e.value}${e.unit}, Android ${t.value}${t.unit}, Web ${r.value}${r.unit}`};let h=[];if(a||h.push(`iOS: expected ${i}pt, got ${e.value}pt`),l||h.push(`Android: expected ${i}${t.unit}, got ${t.value}${t.unit}`),!c)if(r.unit==="rem"){let m=i/o;h.push(`Web: expected ${m}rem, got ${r.value}rem`)}else h.push(`Web: expected ${i}px, got ${r.value}px`);return{consistent:!1,reasoning:`Mathematical inconsistency detected: ${h.join("; ")}`}}isTypographyToken(i,e){return e==="typography"?!0:[/font/i,/text/i,/typography/i,/lineHeight/i,/letterSpacing/i].some(r=>r.test(i))}roundToPrecision(i,e){let t=Math.pow(10,e);return Math.round(i*t)/t}applyScaleWithRounding(i,e){let t=i*e,r=Math.round(t),s=Math.abs(t-r);return s>.5&&console.warn(`Rounding precision loss: ${i}px \xD7 ${e} = ${t}px \u2192 ${r}px (loss: ${s.toFixed(2)}px)`),r}convertToPlatform(i,e,t,r={}){switch(t){case"ios":return this.convertToiOS(i,e,r);case"android":return this.convertToAndroid(i,e,r);case"web":return this.convertToWeb(i,e,r);default:throw new Error(`Unknown platform: ${t}`)}}},Fr=new Me;var N={space075:{value:6,derivation:"space100 \xD7 0.75"},space125:{value:10,derivation:"space100 \xD7 1.25"},space250:{value:20,derivation:"space100 \xD7 2.5"}},v=8;function B(n){return{web:{value:n,unit:"px"},ios:{value:n,unit:"pt"},android:{value:n,unit:"dp"}}}var mt={space000:{name:"space000",category:"spacing",baseValue:0,familyBaseValue:v,description:"Zero spacing - explicit no spacing value",mathematicalRelationship:"base \xD7 0 = 8 \xD7 0 = 0",baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(0)},space025:{name:"space025",category:"spacing",baseValue:v*.25,familyBaseValue:v,description:"Extra tight spacing - 0.25x base value",mathematicalRelationship:"base \xD7 0.25 = 8 \xD7 0.25 = 2",baselineGridAlignment:!1,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*.25)},space050:{name:"space050",category:"spacing",baseValue:v*.5,familyBaseValue:v,description:"Tight spacing - 0.5x base value",mathematicalRelationship:"base \xD7 0.5 = 8 \xD7 0.5 = 4",baselineGridAlignment:!1,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*.5)},space075:{name:"space075",category:"spacing",baseValue:N.space075.value,familyBaseValue:v,description:"Strategic flexibility spacing - 0.75x base value",mathematicalRelationship:N.space075.derivation,baselineGridAlignment:!1,isStrategicFlexibility:!0,isPrecisionTargeted:!1,platforms:B(N.space075.value)},space100:{name:"space100",category:"spacing",baseValue:v,familyBaseValue:v,description:"Base spacing - 1x base value",mathematicalRelationship:"base \xD7 1 = 8 \xD7 1 = 8",baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v)},space125:{name:"space125",category:"spacing",baseValue:N.space125.value,familyBaseValue:v,description:"Strategic flexibility spacing - 1.25x base value",mathematicalRelationship:N.space125.derivation,baselineGridAlignment:!1,isStrategicFlexibility:!0,isPrecisionTargeted:!1,platforms:B(N.space125.value)},space150:{name:"space150",category:"spacing",baseValue:v*1.5,familyBaseValue:v,description:"Loose spacing - 1.5x base value",mathematicalRelationship:"base \xD7 1.5 = 8 \xD7 1.5 = 12",baselineGridAlignment:!1,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*1.5)},space200:{name:"space200",category:"spacing",baseValue:v*2,familyBaseValue:v,description:"Wide spacing - 2x base value",mathematicalRelationship:"base \xD7 2 = 8 \xD7 2 = 16",baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*2)},space250:{name:"space250",category:"spacing",baseValue:N.space250.value,familyBaseValue:v,description:"Strategic flexibility spacing - 2.5x base value",mathematicalRelationship:N.space250.derivation,baselineGridAlignment:!1,isStrategicFlexibility:!0,isPrecisionTargeted:!1,platforms:B(N.space250.value)},space300:{name:"space300",category:"spacing",baseValue:v*3,familyBaseValue:v,description:"Extra wide spacing - 3x base value",mathematicalRelationship:"base \xD7 3 = 8 \xD7 3 = 24",baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*3)},space400:{name:"space400",category:"spacing",baseValue:v*4,familyBaseValue:v,description:"Large spacing - 4x base value",mathematicalRelationship:"base \xD7 4 = 8 \xD7 4 = 32",baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*4)},space500:{name:"space500",category:"spacing",baseValue:v*5,familyBaseValue:v,description:"Extra large spacing - 5x base value",mathematicalRelationship:"base \xD7 5 = 8 \xD7 5 = 40",baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*5)},space600:{name:"space600",category:"spacing",baseValue:v*6,familyBaseValue:v,description:"Huge spacing - 6x base value",mathematicalRelationship:"base \xD7 6 = 8 \xD7 6 = 48",baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*6)},space700:{name:"space700",category:"spacing",baseValue:v*7,familyBaseValue:v,description:"Extra huge spacing - 7x base value",mathematicalRelationship:"base \xD7 7 = 8 \xD7 7 = 56",baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*7)},space800:{name:"space800",category:"spacing",baseValue:v*8,familyBaseValue:v,description:"Maximum spacing - 8x base value",mathematicalRelationship:"base \xD7 8 = 8 \xD7 8 = 64",baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:B(v*8)}},Yo=Object.keys(mt);var Gr=Q({component:"VerticalListItem",family:"spacing",tokens:{"paddingBlock.rest":{value:v*1.375,reasoning:"Block padding at rest state (1px border). 11px padding + 1px border = 12px per side, achieving 48px total with 24px content. Uses TokenWithValue pattern as no primitive token exists for 11px."},"paddingBlock.selected":{reference:mt.space125,reasoning:"Block padding when selected (2px border). 10px padding + 2px border = 12px per side, maintaining 48px total with 24px content. References space125 strategic flexibility token."}}});function ni(n){return Gr[`paddingBlock.${n}`]}var si=":host{display:block;width:100%;--_vlbi-focus-offset:var(--accessibility-focus-offset);--_vlbi-focus-width:var(--accessibility-focus-width);--_vlbi-focus-color:var(--accessibility-focus-color);--_vlbi-min-height:var(--tap-area-recommended);--_vlbi-radius:var(--radius-normal);--_vlbi-padding-inline:var(--space-inset-200);--_vlbi-gap:var(--space-grouped-loose);--_vlbi-label-font-size:var(--typography-button-md-font-size);--_vlbi-label-font-weight:var(--typography-button-md-font-weight);--_vlbi-label-line-height:var(--typography-button-md-line-height);--_vlbi-description-font-size:var(--typography-body-sm-font-size);--_vlbi-description-font-weight:var(--typography-body-sm-font-weight);--_vlbi-description-line-height:var(--typography-body-sm-line-height);--_vlbi-description-color:var(--color-text-muted);--_vlbi-transition-duration:var(--motion-selection-transition-duration);--_vlbi-transition-easing:var(--motion-selection-transition-easing)}.vertical-list-item{appearance:none;margin:0;font:inherit;display:flex;align-items:center;gap:var(--_vlbi-gap);width:100%;min-height:var(--_vlbi-min-height);padding-block:var(--_vlbi-padding-block);padding-inline:var(--_vlbi-padding-inline);background:var(--_vlbi-background);border:var(--_vlbi-border-width) solid var(--_vlbi-border-color);border-radius:var(--_vlbi-radius);text-align:start;cursor:pointer;transition:background var(--_vlbi-transition-duration) var(--_vlbi-transition-easing),background-color var(--_vlbi-transition-duration) var(--_vlbi-transition-easing),border-color var(--_vlbi-transition-duration) var(--_vlbi-transition-easing),border-width var(--_vlbi-transition-duration) var(--_vlbi-transition-easing),padding var(--_vlbi-transition-duration) var(--_vlbi-transition-easing),color var(--_vlbi-transition-duration) var(--_vlbi-transition-easing);outline:none}.vertical-list-item:hover{background-color:var(--_vlbi-hover-bg)}.vertical-list-item:active{background-color:var(--_vlbi-pressed-bg)}.vertical-list-item:focus-visible{outline:var(--_vlbi-focus-width) solid var(--_vlbi-focus-color);outline-offset:var(--_vlbi-focus-offset)}.vertical-list-item:focus:not(:focus-visible){outline:none}.vertical-list-item__content{display:flex;flex-direction:column;flex:1;min-width:0}.vertical-list-item__label{color:var(--_vlbi-label-color);font-size:var(--_vlbi-label-font-size);font-weight:var(--_vlbi-label-font-weight);line-height:var(--_vlbi-label-line-height);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.vertical-list-item__description{color:var(--_vlbi-description-color);font-size:var(--_vlbi-description-font-size);font-weight:var(--_vlbi-description-font-weight);line-height:var(--_vlbi-description-line-height)}.vertical-list-item__leading-icon{flex-shrink:0;display:inline-flex;align-items:center;justify-content:center}.vertical-list-item__checkmark{flex-shrink:0;color:var(--_vlbi-icon-color);display:inline-flex;align-items:center;justify-content:center;transition:opacity var(--_vlbi-transition-duration) var(--_vlbi-transition-easing),visibility var(--_vlbi-transition-duration) var(--_vlbi-transition-easing)}.vertical-list-item__checkmark--fade{opacity:inherit}.vertical-list-item__checkmark--instant.vertical-list-item__checkmark--hidden{transition:none}.vertical-list-item__checkmark--hidden{opacity:0;visibility:hidden}.vertical-list-item__checkmark--visible{opacity:1;visibility:visible}@media (prefers-contrast:high){.vertical-list-item{border-width:2px !important}.vertical-list-item:focus-visible{outline-width:4px}}@media (prefers-reduced-motion:reduce){.vertical-list-item,.vertical-list-item__checkmark--fade{transition:none}}@media print{.vertical-list-item{background-color:transparent !important;border:1px solid currentColor !important;filter:none !important}}";var Wr=["--color-structure-canvas","--color-text-default","--color-text-muted","--color-feedback-select-text-rest","--color-feedback-select-background-rest","--color-feedback-select-text-default","--color-feedback-select-background-default","--color-feedback-error-text","--color-feedback-error-background","--border-default","--border-emphasis","--radius-normal","--space-inset-200","--space-grouped-loose","--tap-area-recommended","--accessibility-focus-width","--accessibility-focus-offset","--accessibility-focus-color","--motion-selection-transition-duration","--motion-selection-transition-easing"];function jr(){let n=getComputedStyle(document.documentElement),i=[];for(let e of Wr)n.getPropertyValue(e).trim()||i.push(e);if(i.length>0)throw new Error(`Button-VerticalList-Item: Missing required CSS variables: ${i.join(", ")}. Ensure Rosetta-generated tokens are loaded before using this component.`)}function Kr(n,i=!1){let e=n==="rest"||n==="selected"||n==="notSelected",r=ii(n)||i&&e?"selected":"rest";return`${ni(r)}px`}function oi(n){let i=n.match(/var\(([^)]+)\)/);if(!i)return n;let e=i[1].trim();return getComputedStyle(document.documentElement).getPropertyValue(e).trim()||n}var ee=class extends HTMLElement{constructor(){super();this._tokensValidated=!1;this._domCreated=!1;this._button=null;this._labelEl=null;this._descriptionEl=null;this._leadingIconContainer=null;this._leadingIconEl=null;this._checkmarkContainer=null;this._checkmarkIconEl=null;this._hoverColor="";this._pressedColor="";this._handleClick=()=>{this._onClick&&this._onClick()};this._handleFocus=()=>{this._onFocus&&this._onFocus(),this.dispatchEvent(new CustomEvent("focus",{bubbles:!0,composed:!0}))};this._handleBlur=()=>{this._onBlur&&this._onBlur(),this.dispatchEvent(new CustomEvent("blur",{bubbles:!0,composed:!0}))};this._handleKeyDown=e=>{(e.key==="Enter"||e.key===" ")&&(e.preventDefault(),this._handleClick())};this._shadowRoot=this.attachShadow({mode:"open",delegatesFocus:!0}),this._blendUtils=E()}static get observedAttributes(){return["label","description","leading-icon","visual-state","error","checkmark-transition","transition-delay","test-id","role","aria-checked","disabled"]}connectedCallback(){document.readyState==="loading"?document.addEventListener("DOMContentLoaded",()=>{this._validateAndRender()},{once:!0}):this._validateAndRender()}_validateAndRender(){this._tokensValidated||(jr(),this._tokensValidated=!0),this._calculateBlendColorsWithRetry(),this._render()}_calculateBlendColorsWithRetry(){try{this._calculateBlendColors()}catch(e){requestAnimationFrame(()=>{try{this._calculateBlendColors(),this._render()}catch(t){console.warn("ButtonVerticalListItem: Could not calculate blend colors, using CSS fallbacks",t)}})}}_calculateBlendColors(){let t=getComputedStyle(document.documentElement).getPropertyValue("--color-structure-canvas").trim();if(!t)throw new Error("Button-VerticalList-Item: Required token --color-structure-canvas is missing from CSS custom properties");this._hoverColor=this._blendUtils.hoverColor(t),this._pressedColor=this._blendUtils.pressedColor(t)}disconnectedCallback(){this._detachEventListeners()}attributeChangedCallback(e,t,r){if(e==="disabled")throw new Error('Button-VerticalList-Item: The "disabled" attribute is not supported. Per accessibility standards, unavailable options should be hidden rather than disabled. Remove the disabled attribute and hide the component instead.');t!==r&&this.isConnected&&this._tokensValidated&&this._domCreated&&this._updateDOM()}get label(){return this.getAttribute("label")||""}set label(e){this.setAttribute("label",e)}get description(){return this.getAttribute("description")||void 0}set description(e){e?this.setAttribute("description",e):this.removeAttribute("description")}get leadingIcon(){return this.getAttribute("leading-icon")}set leadingIcon(e){e?this.setAttribute("leading-icon",e):this.removeAttribute("leading-icon")}get visualState(){let e=this.getAttribute("visual-state");return e&&["rest","selected","notSelected","checked","unchecked"].includes(e)?e:"rest"}set visualState(e){this.setAttribute("visual-state",e)}get error(){return this.getAttribute("error")==="true"}set error(e){this.setAttribute("error",e.toString())}get checkmarkTransition(){return this.getAttribute("checkmark-transition")==="instant"?"instant":"fade"}set checkmarkTransition(e){this.setAttribute("checkmark-transition",e)}get transitionDelay(){let e=this.getAttribute("transition-delay");return e?parseInt(e,10):0}set transitionDelay(e){this.setAttribute("transition-delay",e.toString())}get testID(){return this.getAttribute("test-id")||void 0}set testID(e){e?this.setAttribute("test-id",e):this.removeAttribute("test-id")}get disabled(){return!1}set disabled(e){if(e)throw new Error('Button-VerticalList-Item: The "disabled" property is not supported. Per accessibility standards, unavailable options should be hidden rather than disabled. Set disabled to false or hide the component instead.')}get itemRole(){let e=this.getAttribute("role");return e==="radio"||e==="checkbox"?e:"button"}set itemRole(e){this.setAttribute("role",e)}get itemAriaChecked(){let e=this.getAttribute("aria-checked");if(e==="true")return!0;if(e==="false")return!1}set itemAriaChecked(e){e===void 0?this.removeAttribute("aria-checked"):this.setAttribute("aria-checked",e.toString())}set onClick(e){this._onClick=e}get onClick(){return this._onClick}set onFocus(e){this._onFocus=e}get onFocus(){return this._onFocus}set onBlur(e){this._onBlur=e}get onBlur(){return this._onBlur}_render(){this._domCreated?this._updateDOM():(this._createDOM(),this._domCreated=!0,this._attachEventListeners())}_createDOM(){var t,r;let e=A.size100;this._shadowRoot.innerHTML=`
|
|
306
306
|
<style>${si}</style>
|
|
307
307
|
<button
|
|
308
308
|
class="vertical-list-item"
|
|
@@ -335,7 +335,7 @@
|
|
|
335
335
|
></div>
|
|
336
336
|
<slot></slot>
|
|
337
337
|
</div>
|
|
338
|
-
`,this._container=this._shadowRoot.querySelector(".vls-container"),this._errorMessageEl=this._shadowRoot.querySelector(".vls-error-message"),this._updateDOM()}_updateDOM(){if(!this._container)return;let e=gi(this._mode);this._container.setAttribute("role",e),this._mode==="multiSelect"?this._container.setAttribute("aria-multiselectable","true"):this._container.removeAttribute("aria-multiselectable"),this._error&&this._errorMessage?(this._container.setAttribute("aria-invalid","true"),this._container.setAttribute("aria-describedby",this._errorMessageId)):(this._container.removeAttribute("aria-invalid"),this._container.removeAttribute("aria-describedby")),this._testID?this._container.setAttribute("data-testid",this._testID):this._container.removeAttribute("data-testid"),this._errorMessageEl&&(this._error&&this._errorMessage?(this._errorMessageEl.textContent=this._errorMessage,this._errorMessageEl.style.display=""):(this._errorMessageEl.textContent="",this._errorMessageEl.style.display="none")),this._updateChildItems()}_updateChildItems(){let e=this._shadowRoot.querySelector("slot");if(!e)return;let t=e.assignedElements(),r=t.length,s=hi(this._mode,this._selectedIndex,this._selectedIndices,r),o=this._calculateTransitionDelays(r,s),a=this._calculateCheckmarkTransitions(r,s),l=this._getItemRole();this._internalState.focusedIndex>=r&&(this._internalState.focusedIndex=Math.max(0,r-1)),t.forEach((c,d)=>{if(c.tagName.toLowerCase()==="button-vertical-list-item"){let h=s[d];c.setAttribute("visual-state",h);let u=o[d];c.setAttribute("transition-delay",String(u));let m=a[d];if(c.setAttribute("checkmark-transition",m==="instant"?"instant":"fade"),this._error?c.setAttribute("error","true"):c.setAttribute("error","false"),c.setAttribute("role",l),l==="radio"||l==="checkbox"){let g=this._getItemAriaChecked(d,h);c.setAttribute("aria-checked",g?"true":"false")}else c.removeAttribute("aria-checked");d===this._internalState.focusedIndex?c.setAttribute("tabindex","0"):c.setAttribute("tabindex","-1")}})}_getItemRole(){switch(this._mode){case"tap":return"button";case"select":return"radio";case"multiSelect":return"checkbox";default:return"button"}}_getItemAriaChecked(e,t){switch(this._mode){case"select":return t==="selected";case"multiSelect":return t==="checked";default:return!1}}_calculateTransitionDelays(e,t){if(this._mode==="tap")return Array(e).fill(0);if(this._mode==="multiSelect")return ui(0,e);if(this._mode==="select"){let r=this._internalState.previousSelectedIndex,s=this._selectedIndex;return this._internalState.isFirstSelection&&s!==null?ci(e):s===null&&r!==null?di(e):r!==null&&s!==null&&r!==s?li(r,s,e):Array(e).fill(0)}return Array(e).fill(0)}_calculateCheckmarkTransitions(e,t){if(this._mode==="tap"||this._mode==="multiSelect")return Array(e).fill("animated");if(this._mode==="select"){let r=this._internalState.previousSelectedIndex,s=this._selectedIndex,o=Array(e).fill("animated");return r!==null&&s!==null&&r!==s&&(o[r]=Qe(!0,this._mode),o[s]=Qe(!1,this._mode)),s===null&&r!==null&&(o[r]=Qe(!0,this._mode)),o}return Array(e).fill("animated")}_attachEventListeners(){let e=this._shadowRoot.querySelector("slot");e&&e.addEventListener("slotchange",this._handleSlotChange),this.addEventListener("click",this._handleChildClick),this.addEventListener("keydown",this._handleKeyDown),this.addEventListener("focusin",this._handleFocusIn)}_detachEventListeners(){let e=this._shadowRoot.querySelector("slot");e&&e.removeEventListener("slotchange",this._handleSlotChange),this.removeEventListener("click",this._handleChildClick),this.removeEventListener("keydown",this._handleKeyDown),this.removeEventListener("focusin",this._handleFocusIn)}_handleSelectModeClick(e){let t;this._selectedIndex===e?t=null:t=e,this._internalState.previousSelectedIndex=this._selectedIndex,t===null?this._internalState.isFirstSelection=!0:this._internalState.isFirstSelection&&(this._internalState.isFirstSelection=!1),this._error&&this._required&&t!==null&&Je(this._mode,t,this._selectedIndices,this._required,this._minSelections,this._maxSelections).isValid&&(this._error=!1,this._errorMessage=void 0,this.removeAttribute("error"),this.removeAttribute("error-message"),this._domCreated&&this._updateDOM()),this._onSelectionChange&&this._onSelectionChange(t)}_handleMultiSelectModeClick(e){if(!ai(e,this._selectedIndices,this._maxSelections))return;let t;this._selectedIndices.includes(e)?t=this._selectedIndices.filter(r=>r!==e):t=[...this._selectedIndices,e],this._error&&Je(this._mode,this._selectedIndex,t,this._required,this._minSelections,this._maxSelections).isValid&&(this._error=!1,this._errorMessage=void 0,this.removeAttribute("error"),this.removeAttribute("error-message"),this._domCreated&&this._updateDOM()),this._onMultiSelectionChange&&this._onMultiSelectionChange(t)}_processKeyboardNavigation(e,t){let r=this._internalState.focusedIndex;switch(e.key){case"ArrowDown":return{newFocusIndex:(r+1)%t,shouldActivate:!1,handled:!0};case"ArrowUp":return{newFocusIndex:(r-1+t)%t,shouldActivate:!1,handled:!0};case"Home":return{newFocusIndex:0,shouldActivate:!1,handled:!0};case"End":return{newFocusIndex:t-1,shouldActivate:!1,handled:!0};case"Enter":case" ":return{newFocusIndex:r,shouldActivate:!0,handled:!0};default:return{newFocusIndex:r,shouldActivate:!1,handled:!1}}}_moveFocusToIndex(e,t){let r=t||this._getChildItems();if(r.length===0||e<0||e>=r.length)return;this._internalState.focusedIndex=e,this._updateTabIndices(r,e);let s=r[e];s&&s.focus()}_updateTabIndices(e,t){e.forEach((r,s)=>{s===t?r.setAttribute("tabindex","0"):r.setAttribute("tabindex","-1")})}_activateItem(e){switch(this._mode){case"tap":this._onItemClick&&this._onItemClick(e);break;case"select":this._handleSelectModeClick(e);break;case"multiSelect":this._handleMultiSelectModeClick(e);break}}_getChildItems(){let e=this._shadowRoot.querySelector("slot");return e?e.assignedElements().filter(t=>t.tagName.toLowerCase()==="button-vertical-list-item"):[]}};typeof customElements!="undefined"&&!customElements.get("button-vertical-list-set")&&customElements.define("button-vertical-list-set",te);var bt={type:"human",size:"md",interactive:!1,decorative:!1};var p=8;function L(n){return{web:{value:n,unit:"px"},ios:{value:n,unit:"pt"},android:{value:n,unit:"dp"}}}var W={size050:{name:"size050",category:"sizing",baseValue:p*.5,familyBaseValue:p,description:"Size 050 - smallest component dimension",mathematicalRelationship:`base \xD7 0.5 = ${p} \xD7 0.5 = ${p*.5}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*.5)},size100:{name:"size100",category:"sizing",baseValue:p,familyBaseValue:p,description:"Size 100 - base component dimension",mathematicalRelationship:`base \xD7 1 = ${p} \xD7 1 = ${p}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p)},size150:{name:"size150",category:"sizing",baseValue:p*1.5,familyBaseValue:p,description:"Size 150 - small component dimension",mathematicalRelationship:`base \xD7 1.5 = ${p} \xD7 1.5 = ${p*1.5}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*1.5)},size200:{name:"size200",category:"sizing",baseValue:p*2,familyBaseValue:p,description:"Size 200 - medium-small component dimension",mathematicalRelationship:`base \xD7 2 = ${p} \xD7 2 = ${p*2}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*2)},size250:{name:"size250",category:"sizing",baseValue:p*2.5,familyBaseValue:p,description:"Size 250 - medium component dimension",mathematicalRelationship:`base \xD7 2.5 = ${p} \xD7 2.5 = ${p*2.5}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*2.5)},size300:{name:"size300",category:"sizing",baseValue:p*3,familyBaseValue:p,description:"Size 300 - standard component dimension",mathematicalRelationship:`base \xD7 3 = ${p} \xD7 3 = ${p*3}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*3)},size400:{name:"size400",category:"sizing",baseValue:p*4,familyBaseValue:p,description:"Size 400 - large component dimension",mathematicalRelationship:`base \xD7 4 = ${p} \xD7 4 = ${p*4}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*4)},size500:{name:"size500",category:"sizing",baseValue:p*5,familyBaseValue:p,description:"Size 500 - extra-large component dimension",mathematicalRelationship:`base \xD7 5 = ${p} \xD7 5 = ${p*5}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*5)},size600:{name:"size600",category:"sizing",baseValue:p*6,familyBaseValue:p,description:"Size 600 - prominent component dimension",mathematicalRelationship:`base \xD7 6 = ${p} \xD7 6 = ${p*6}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*6)},size700:{name:"size700",category:"sizing",baseValue:p*7,familyBaseValue:p,description:"Size 700 - large prominent component dimension",mathematicalRelationship:`base \xD7 7 = ${p} \xD7 7 = ${p*7}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*7)},size800:{name:"size800",category:"sizing",baseValue:p*8,familyBaseValue:p,description:"Size 800 - extra-large prominent component dimension",mathematicalRelationship:`base \xD7 8 = ${p} \xD7 8 = ${p*8}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*8)},size900:{name:"size900",category:"sizing",baseValue:p*9,familyBaseValue:p,description:"Size 900 - large prominent component dimension",mathematicalRelationship:`base \xD7 9 = ${p} \xD7 9 = ${p*9}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*9)},size1000:{name:"size1000",category:"sizing",baseValue:p*10,familyBaseValue:p,description:"Size 1000 - hero component dimension",mathematicalRelationship:`base \xD7 10 = ${p} \xD7 10 = ${p*10}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*10)},size1600:{name:"size1600",category:"sizing",baseValue:p*16,familyBaseValue:p,description:"Size 1600 - maximum component dimension",mathematicalRelationship:`base \xD7 16 = ${p} \xD7 16 = ${p*16}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*16)}},ka=Object.keys(W);var ie=G({component:"Avatar",family:"sizing",tokens:{"size.xs":{reference:W.size300,reasoning:"Extra small avatar (24px). Compact contexts \u2014 inline mentions, dense lists."},"size.sm":{reference:W.size400,reasoning:"Small avatar (32px). Comment threads, contact lists."},"size.md":{reference:W.size500,reasoning:"Medium avatar (40px). Default size \u2014 profile cards, list items."},"size.lg":{reference:W.size600,reasoning:"Large avatar (48px). Profile headers, prominent identity display."},"size.xl":{reference:W.size1000,reasoning:"Extra large avatar (80px). Profile pages, hero sections."},"size.xxl":{reference:W.size1600,reasoning:"Extra extra large avatar (128px). Full profile view, onboarding."}}}),wa=G({component:"Avatar",family:"spacing",tokens:{"icon.size.xs":{value:p*1.5,reasoning:"Icon size for xs avatar (12px = 1.5\xD7 base) maintains 50% ratio (12/24). No existing icon token at this size, so component token fills the gap."},"icon.size.xxl":{value:p*8,reasoning:"Icon size for xxl avatar (64px = 8\xD7 base) maintains 50% ratio (64/128). No existing icon token at this size, so component token fills the gap."}}});var vt=".avatar{display:flex;align-items:center;justify-content:center;box-sizing:border-box;overflow:hidden;flex-shrink:0}.avatar--human{border-radius:var(--radius-half)}.avatar--agent{aspect-ratio:1;position:relative;border:none !important;background-color:transparent}.avatar--size-xs{height:calc(var(--icon-size-050) * 1.5)}.avatar--human.avatar--size-xs{width:calc(var(--icon-size-050) * 1.5)}.avatar--size-sm{height:calc(var(--icon-size-050) * 2)}.avatar--human.avatar--size-sm{width:calc(var(--icon-size-050) * 2)}.avatar--size-md{height:calc(var(--icon-size-075) * 2)}.avatar--human.avatar--size-md{width:calc(var(--icon-size-075) * 2)}.avatar--size-lg{height:calc(var(--icon-size-100) * 2)}.avatar--human.avatar--size-lg{width:calc(var(--icon-size-100) * 2)}.avatar--size-xl{height:calc(var(--icon-size-500) * 2)}.avatar--human.avatar--size-xl{width:calc(var(--icon-size-500) * 2)}.avatar--size-xxl{height:calc(var(--icon-size-050) * 8)}.avatar--human.avatar--size-xxl{width:calc(var(--icon-size-050) * 8)}.avatar--human{background-color:var(--color-identity-human)}.avatar{border-width:var(--border-default);border-style:solid;border-color:color-mix(in oklch,var(--color-structure-border) 48%,transparent)}.avatar--size-xxl{border-width:var(--border-emphasis);border-color:var(--color-contrast-on-dark)}.avatar--interactive{cursor:pointer;transition:border-width var(--motion-focus-transition-duration) var(--motion-focus-transition-easing)}.avatar--interactive:hover{border-width:var(--border-emphasis)}@media (prefers-reduced-motion:reduce){.avatar--interactive{transition:none}}@media (prefers-contrast:high){.avatar{border:var(--border-emphasis) solid currentColor}}.avatar__icon{display:flex;align-items:center;justify-content:center;flex-shrink:0;line-height:0}.avatar__icon--human{color:var(--color-contrast-on-dark)}.avatar__icon--agent{color:var(--color-contrast-on-dark)}.avatar__icon-svg{width:100%;height:100%;display:block}.avatar__icon .icon-base{color:inherit}.avatar__image{width:100%;height:100%;object-fit:cover;display:block}.avatar--has-image{background-color:transparent}.avatar__hexagon-svg{position:absolute;top:0;left:0;pointer-events:none}.avatar__hexagon-bg{}.avatar__hexagon-border{transition:stroke-width var(--motion-focus-transition-duration) var(--motion-focus-transition-easing)}.avatar--agent.avatar--interactive:hover .avatar__hexagon-border{stroke-width:var(--border-emphasis)}.avatar__content{position:absolute;top:0;left:0;width:100%;height:100%;display:flex;align-items:center;justify-content:center;z-index:1}.avatar--agent.avatar--size-xs{width:calc(var(--icon-size-050) * 1.5)}.avatar--agent.avatar--size-sm{width:calc(var(--icon-size-050) * 2)}.avatar--agent.avatar--size-md{width:calc(var(--icon-size-075) * 2)}.avatar--agent.avatar--size-lg{width:calc(var(--icon-size-100) * 2)}.avatar--agent.avatar--size-xl{width:calc(var(--icon-size-500) * 2)}.avatar--agent.avatar--size-xxl{width:calc(var(--icon-size-050) * 8)}";function Zr(n,i){let e=i!=null?i:n*.08,t=n/2,r=n/2,s=n,a=n*Math.cos(Math.PI/6)/2,l=s/4,c=[{x:t,y:0},{x:t+a,y:l},{x:t+a,y:3*l},{x:t,y:s},{x:t-a,y:3*l},{x:t-a,y:l}],d=[],h=c.length;for(let w=0;w<h;w++){let I=c[w],Y=c[(w+1)%h],H=c[(w-1+h)%h],$={x:H.x-I.x,y:H.y-I.y},M={x:Y.x-I.x,y:Y.y-I.y},St=Math.sqrt($.x*$.x+$.y*$.y),Et=Math.sqrt(M.x*M.x+M.y*M.y),wt={x:$.x/St,y:$.y/St},At={x:M.x/Et,y:M.y/Et},Tt={x:I.x+wt.x*e,y:I.y+wt.y*e},Fe={x:I.x+At.x*e,y:I.y+At.y*e};w===0?d.push(`M ${Fe.x.toFixed(2)} ${Fe.y.toFixed(2)}`):(d.push(`L ${Tt.x.toFixed(2)} ${Tt.y.toFixed(2)}`),d.push(`Q ${I.x.toFixed(2)} ${I.y.toFixed(2)} ${Fe.x.toFixed(2)} ${Fe.y.toFixed(2)}`))}let u=c[0],m=c[1],g=c[h-1],f={x:g.x-u.x,y:g.y-u.y},b={x:m.x-u.x,y:m.y-u.y},x=Math.sqrt(f.x*f.x+f.y*f.y),C=Math.sqrt(b.x*b.x+b.y*b.y),_={x:f.x/x,y:f.y/x},S={x:b.x/C,y:b.y/C},k={x:u.x+_.x*e,y:u.y+_.y*e},T={x:u.x+S.x*e,y:u.y+S.y*e};return d.push(`L ${k.x.toFixed(2)} ${k.y.toFixed(2)}`),d.push(`Q ${u.x.toFixed(2)} ${u.y.toFixed(2)} ${T.x.toFixed(2)} ${T.y.toFixed(2)}`),d.push("Z"),d.join(" ")}var Yr={xs:"xs",sm:13,md:20,lg:24,xl:40,xxl:"xxl"},Xr={xs:ie["size.xs"],sm:ie["size.sm"],md:ie["size.md"],lg:ie["size.lg"],xl:ie["size.xl"],xxl:ie["size.xxl"]},Jr={human:"user",agent:"settings"},j=class extends HTMLElement{static get observedAttributes(){return["type","size","src","alt","interactive","decorative","testid"]}constructor(){super(),this._shadowRoot=this.attachShadow({mode:"open"})}connectedCallback(){this.render()}attributeChangedCallback(i,e,t){e!==t&&this.isConnected&&this.render()}get type(){let i=this.getAttribute("type");return i==="human"||i==="agent"?i:bt.type}set type(i){this.setAttribute("type",i)}get size(){let i=this.getAttribute("size");return["xs","sm","md","lg","xl","xxl"].includes(i)?i:bt.size}set size(i){this.setAttribute("size",i)}get src(){return this.getAttribute("src")}set src(i){i?this.setAttribute("src",i):this.removeAttribute("src")}get alt(){return this.getAttribute("alt")}set alt(i){i?this.setAttribute("alt",i):this.removeAttribute("alt")}get interactive(){return this.getAttribute("interactive")==="true"}set interactive(i){i?this.setAttribute("interactive","true"):this.removeAttribute("interactive")}get decorative(){return this.getAttribute("decorative")==="true"}set decorative(i){i?this.setAttribute("decorative","true"):this.removeAttribute("decorative")}get testID(){return this.getAttribute("testid")}set testID(i){i?this.setAttribute("testid",i):this.removeAttribute("testid")}renderIconContent(i,e){let t=Jr[i],r=Yr[e];if(r==="xs"||r==="xxl"){let o=r==="xs"?"calc(var(--icon-size-050) * 0.75)":"calc(var(--icon-size-050) * 4)",a=this.getIconSVGContent(t);return`
|
|
338
|
+
`,this._container=this._shadowRoot.querySelector(".vls-container"),this._errorMessageEl=this._shadowRoot.querySelector(".vls-error-message"),this._updateDOM()}_updateDOM(){if(!this._container)return;let e=gi(this._mode);this._container.setAttribute("role",e),this._mode==="multiSelect"?this._container.setAttribute("aria-multiselectable","true"):this._container.removeAttribute("aria-multiselectable"),this._error&&this._errorMessage?(this._container.setAttribute("aria-invalid","true"),this._container.setAttribute("aria-describedby",this._errorMessageId)):(this._container.removeAttribute("aria-invalid"),this._container.removeAttribute("aria-describedby")),this._testID?this._container.setAttribute("data-testid",this._testID):this._container.removeAttribute("data-testid"),this._errorMessageEl&&(this._error&&this._errorMessage?(this._errorMessageEl.textContent=this._errorMessage,this._errorMessageEl.style.display=""):(this._errorMessageEl.textContent="",this._errorMessageEl.style.display="none")),this._updateChildItems()}_updateChildItems(){let e=this._shadowRoot.querySelector("slot");if(!e)return;let t=e.assignedElements(),r=t.length,s=hi(this._mode,this._selectedIndex,this._selectedIndices,r),o=this._calculateTransitionDelays(r,s),a=this._calculateCheckmarkTransitions(r,s),l=this._getItemRole();this._internalState.focusedIndex>=r&&(this._internalState.focusedIndex=Math.max(0,r-1)),t.forEach((c,d)=>{if(c.tagName.toLowerCase()==="button-vertical-list-item"){let h=s[d];c.setAttribute("visual-state",h);let u=o[d];c.setAttribute("transition-delay",String(u));let m=a[d];if(c.setAttribute("checkmark-transition",m==="instant"?"instant":"fade"),this._error?c.setAttribute("error","true"):c.setAttribute("error","false"),c.setAttribute("role",l),l==="radio"||l==="checkbox"){let g=this._getItemAriaChecked(d,h);c.setAttribute("aria-checked",g?"true":"false")}else c.removeAttribute("aria-checked");d===this._internalState.focusedIndex?c.setAttribute("tabindex","0"):c.setAttribute("tabindex","-1")}})}_getItemRole(){switch(this._mode){case"tap":return"button";case"select":return"radio";case"multiSelect":return"checkbox";default:return"button"}}_getItemAriaChecked(e,t){switch(this._mode){case"select":return t==="selected";case"multiSelect":return t==="checked";default:return!1}}_calculateTransitionDelays(e,t){if(this._mode==="tap")return Array(e).fill(0);if(this._mode==="multiSelect")return ui(0,e);if(this._mode==="select"){let r=this._internalState.previousSelectedIndex,s=this._selectedIndex;return this._internalState.isFirstSelection&&s!==null?ci(e):s===null&&r!==null?di(e):r!==null&&s!==null&&r!==s?li(r,s,e):Array(e).fill(0)}return Array(e).fill(0)}_calculateCheckmarkTransitions(e,t){if(this._mode==="tap"||this._mode==="multiSelect")return Array(e).fill("animated");if(this._mode==="select"){let r=this._internalState.previousSelectedIndex,s=this._selectedIndex,o=Array(e).fill("animated");return r!==null&&s!==null&&r!==s&&(o[r]=Qe(!0,this._mode),o[s]=Qe(!1,this._mode)),s===null&&r!==null&&(o[r]=Qe(!0,this._mode)),o}return Array(e).fill("animated")}_attachEventListeners(){let e=this._shadowRoot.querySelector("slot");e&&e.addEventListener("slotchange",this._handleSlotChange),this.addEventListener("click",this._handleChildClick),this.addEventListener("keydown",this._handleKeyDown),this.addEventListener("focusin",this._handleFocusIn)}_detachEventListeners(){let e=this._shadowRoot.querySelector("slot");e&&e.removeEventListener("slotchange",this._handleSlotChange),this.removeEventListener("click",this._handleChildClick),this.removeEventListener("keydown",this._handleKeyDown),this.removeEventListener("focusin",this._handleFocusIn)}_handleSelectModeClick(e){let t;this._selectedIndex===e?t=null:t=e,this._internalState.previousSelectedIndex=this._selectedIndex,t===null?this._internalState.isFirstSelection=!0:this._internalState.isFirstSelection&&(this._internalState.isFirstSelection=!1),this._error&&this._required&&t!==null&&Je(this._mode,t,this._selectedIndices,this._required,this._minSelections,this._maxSelections).isValid&&(this._error=!1,this._errorMessage=void 0,this.removeAttribute("error"),this.removeAttribute("error-message"),this._domCreated&&this._updateDOM()),this._onSelectionChange&&this._onSelectionChange(t)}_handleMultiSelectModeClick(e){if(!ai(e,this._selectedIndices,this._maxSelections))return;let t;this._selectedIndices.includes(e)?t=this._selectedIndices.filter(r=>r!==e):t=[...this._selectedIndices,e],this._error&&Je(this._mode,this._selectedIndex,t,this._required,this._minSelections,this._maxSelections).isValid&&(this._error=!1,this._errorMessage=void 0,this.removeAttribute("error"),this.removeAttribute("error-message"),this._domCreated&&this._updateDOM()),this._onMultiSelectionChange&&this._onMultiSelectionChange(t)}_processKeyboardNavigation(e,t){let r=this._internalState.focusedIndex;switch(e.key){case"ArrowDown":return{newFocusIndex:(r+1)%t,shouldActivate:!1,handled:!0};case"ArrowUp":return{newFocusIndex:(r-1+t)%t,shouldActivate:!1,handled:!0};case"Home":return{newFocusIndex:0,shouldActivate:!1,handled:!0};case"End":return{newFocusIndex:t-1,shouldActivate:!1,handled:!0};case"Enter":case" ":return{newFocusIndex:r,shouldActivate:!0,handled:!0};default:return{newFocusIndex:r,shouldActivate:!1,handled:!1}}}_moveFocusToIndex(e,t){let r=t||this._getChildItems();if(r.length===0||e<0||e>=r.length)return;this._internalState.focusedIndex=e,this._updateTabIndices(r,e);let s=r[e];s&&s.focus()}_updateTabIndices(e,t){e.forEach((r,s)=>{s===t?r.setAttribute("tabindex","0"):r.setAttribute("tabindex","-1")})}_activateItem(e){switch(this._mode){case"tap":this._onItemClick&&this._onItemClick(e);break;case"select":this._handleSelectModeClick(e);break;case"multiSelect":this._handleMultiSelectModeClick(e);break}}_getChildItems(){let e=this._shadowRoot.querySelector("slot");return e?e.assignedElements().filter(t=>t.tagName.toLowerCase()==="button-vertical-list-item"):[]}};typeof customElements!="undefined"&&!customElements.get("button-vertical-list-set")&&customElements.define("button-vertical-list-set",te);var bt={type:"human",size:"md",interactive:!1,decorative:!1};var p=8;function L(n){return{web:{value:n,unit:"px"},ios:{value:n,unit:"pt"},android:{value:n,unit:"dp"}}}var G={size050:{name:"size050",category:"sizing",baseValue:p*.5,familyBaseValue:p,description:"Size 050 - smallest component dimension",mathematicalRelationship:`base \xD7 0.5 = ${p} \xD7 0.5 = ${p*.5}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*.5)},size100:{name:"size100",category:"sizing",baseValue:p,familyBaseValue:p,description:"Size 100 - base component dimension",mathematicalRelationship:`base \xD7 1 = ${p} \xD7 1 = ${p}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p)},size150:{name:"size150",category:"sizing",baseValue:p*1.5,familyBaseValue:p,description:"Size 150 - small component dimension",mathematicalRelationship:`base \xD7 1.5 = ${p} \xD7 1.5 = ${p*1.5}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*1.5)},size200:{name:"size200",category:"sizing",baseValue:p*2,familyBaseValue:p,description:"Size 200 - medium-small component dimension",mathematicalRelationship:`base \xD7 2 = ${p} \xD7 2 = ${p*2}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*2)},size250:{name:"size250",category:"sizing",baseValue:p*2.5,familyBaseValue:p,description:"Size 250 - medium component dimension",mathematicalRelationship:`base \xD7 2.5 = ${p} \xD7 2.5 = ${p*2.5}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*2.5)},size300:{name:"size300",category:"sizing",baseValue:p*3,familyBaseValue:p,description:"Size 300 - standard component dimension",mathematicalRelationship:`base \xD7 3 = ${p} \xD7 3 = ${p*3}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*3)},size400:{name:"size400",category:"sizing",baseValue:p*4,familyBaseValue:p,description:"Size 400 - large component dimension",mathematicalRelationship:`base \xD7 4 = ${p} \xD7 4 = ${p*4}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*4)},size500:{name:"size500",category:"sizing",baseValue:p*5,familyBaseValue:p,description:"Size 500 - extra-large component dimension",mathematicalRelationship:`base \xD7 5 = ${p} \xD7 5 = ${p*5}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*5)},size600:{name:"size600",category:"sizing",baseValue:p*6,familyBaseValue:p,description:"Size 600 - prominent component dimension",mathematicalRelationship:`base \xD7 6 = ${p} \xD7 6 = ${p*6}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*6)},size700:{name:"size700",category:"sizing",baseValue:p*7,familyBaseValue:p,description:"Size 700 - large prominent component dimension",mathematicalRelationship:`base \xD7 7 = ${p} \xD7 7 = ${p*7}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*7)},size800:{name:"size800",category:"sizing",baseValue:p*8,familyBaseValue:p,description:"Size 800 - extra-large prominent component dimension",mathematicalRelationship:`base \xD7 8 = ${p} \xD7 8 = ${p*8}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*8)},size900:{name:"size900",category:"sizing",baseValue:p*9,familyBaseValue:p,description:"Size 900 - large prominent component dimension",mathematicalRelationship:`base \xD7 9 = ${p} \xD7 9 = ${p*9}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*9)},size1000:{name:"size1000",category:"sizing",baseValue:p*10,familyBaseValue:p,description:"Size 1000 - hero component dimension",mathematicalRelationship:`base \xD7 10 = ${p} \xD7 10 = ${p*10}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*10)},size1600:{name:"size1600",category:"sizing",baseValue:p*16,familyBaseValue:p,description:"Size 1600 - maximum component dimension",mathematicalRelationship:`base \xD7 16 = ${p} \xD7 16 = ${p*16}`,baselineGridAlignment:!0,isStrategicFlexibility:!1,isPrecisionTargeted:!1,platforms:L(p*16)}},ka=Object.keys(G);var ie=Q({component:"Avatar",family:"sizing",tokens:{"size.xs":{reference:G.size300,reasoning:"Extra small avatar (24px). Compact contexts \u2014 inline mentions, dense lists."},"size.sm":{reference:G.size400,reasoning:"Small avatar (32px). Comment threads, contact lists."},"size.md":{reference:G.size500,reasoning:"Medium avatar (40px). Default size \u2014 profile cards, list items."},"size.lg":{reference:G.size600,reasoning:"Large avatar (48px). Profile headers, prominent identity display."},"size.xl":{reference:G.size1000,reasoning:"Extra large avatar (80px). Profile pages, hero sections."},"size.xxl":{reference:G.size1600,reasoning:"Extra extra large avatar (128px). Full profile view, onboarding."},"icon.size.xs":{value:p*1.5,reasoning:"Icon size for xs avatar (12px = 1.5\xD7 base) maintains 50% ratio (12/24). No existing icon token at this size, so component token fills the gap."},"icon.size.xxl":{value:p*8,reasoning:"Icon size for xxl avatar (64px = 8\xD7 base) maintains 50% ratio (64/128). No existing icon token at this size, so component token fills the gap."}}});var vt=".avatar{display:flex;align-items:center;justify-content:center;box-sizing:border-box;overflow:hidden;flex-shrink:0}.avatar--human{border-radius:var(--radius-half)}.avatar--agent{aspect-ratio:1;position:relative;border:none !important;background-color:transparent}.avatar--size-xs{height:calc(var(--icon-size-050) * 1.5)}.avatar--human.avatar--size-xs{width:calc(var(--icon-size-050) * 1.5)}.avatar--size-sm{height:calc(var(--icon-size-050) * 2)}.avatar--human.avatar--size-sm{width:calc(var(--icon-size-050) * 2)}.avatar--size-md{height:calc(var(--icon-size-075) * 2)}.avatar--human.avatar--size-md{width:calc(var(--icon-size-075) * 2)}.avatar--size-lg{height:calc(var(--icon-size-100) * 2)}.avatar--human.avatar--size-lg{width:calc(var(--icon-size-100) * 2)}.avatar--size-xl{height:calc(var(--icon-size-500) * 2)}.avatar--human.avatar--size-xl{width:calc(var(--icon-size-500) * 2)}.avatar--size-xxl{height:calc(var(--icon-size-050) * 8)}.avatar--human.avatar--size-xxl{width:calc(var(--icon-size-050) * 8)}.avatar--human{background-color:var(--color-identity-human)}.avatar{border-width:var(--border-default);border-style:solid;border-color:color-mix(in oklch,var(--color-structure-border) 48%,transparent)}.avatar--size-xxl{border-width:var(--border-emphasis);border-color:var(--color-contrast-on-dark)}.avatar--interactive{cursor:pointer;transition:border-width var(--motion-focus-transition-duration) var(--motion-focus-transition-easing)}.avatar--interactive:hover{border-width:var(--border-emphasis)}@media (prefers-reduced-motion:reduce){.avatar--interactive{transition:none}}@media (prefers-contrast:high){.avatar{border:var(--border-emphasis) solid currentColor}}.avatar__icon{display:flex;align-items:center;justify-content:center;flex-shrink:0;line-height:0}.avatar__icon--human{color:var(--color-contrast-on-dark)}.avatar__icon--agent{color:var(--color-contrast-on-dark)}.avatar__icon-svg{width:100%;height:100%;display:block}.avatar__icon .icon-base{color:inherit}.avatar__image{width:100%;height:100%;object-fit:cover;display:block}.avatar--has-image{background-color:transparent}.avatar__hexagon-svg{position:absolute;top:0;left:0;pointer-events:none}.avatar__hexagon-bg{}.avatar__hexagon-border{transition:stroke-width var(--motion-focus-transition-duration) var(--motion-focus-transition-easing)}.avatar--agent.avatar--interactive:hover .avatar__hexagon-border{stroke-width:var(--border-emphasis)}.avatar__content{position:absolute;top:0;left:0;width:100%;height:100%;display:flex;align-items:center;justify-content:center;z-index:1}.avatar--agent.avatar--size-xs{width:calc(var(--icon-size-050) * 1.5)}.avatar--agent.avatar--size-sm{width:calc(var(--icon-size-050) * 2)}.avatar--agent.avatar--size-md{width:calc(var(--icon-size-075) * 2)}.avatar--agent.avatar--size-lg{width:calc(var(--icon-size-100) * 2)}.avatar--agent.avatar--size-xl{width:calc(var(--icon-size-500) * 2)}.avatar--agent.avatar--size-xxl{width:calc(var(--icon-size-050) * 8)}";function Zr(n,i){let e=i!=null?i:n*.08,t=n/2,r=n/2,s=n,a=n*Math.cos(Math.PI/6)/2,l=s/4,c=[{x:t,y:0},{x:t+a,y:l},{x:t+a,y:3*l},{x:t,y:s},{x:t-a,y:3*l},{x:t-a,y:l}],d=[],h=c.length;for(let w=0;w<h;w++){let I=c[w],Z=c[(w+1)%h],H=c[(w-1+h)%h],$={x:H.x-I.x,y:H.y-I.y},M={x:Z.x-I.x,y:Z.y-I.y},St=Math.sqrt($.x*$.x+$.y*$.y),Et=Math.sqrt(M.x*M.x+M.y*M.y),wt={x:$.x/St,y:$.y/St},At={x:M.x/Et,y:M.y/Et},Tt={x:I.x+wt.x*e,y:I.y+wt.y*e},Fe={x:I.x+At.x*e,y:I.y+At.y*e};w===0?d.push(`M ${Fe.x.toFixed(2)} ${Fe.y.toFixed(2)}`):(d.push(`L ${Tt.x.toFixed(2)} ${Tt.y.toFixed(2)}`),d.push(`Q ${I.x.toFixed(2)} ${I.y.toFixed(2)} ${Fe.x.toFixed(2)} ${Fe.y.toFixed(2)}`))}let u=c[0],m=c[1],g=c[h-1],f={x:g.x-u.x,y:g.y-u.y},b={x:m.x-u.x,y:m.y-u.y},x=Math.sqrt(f.x*f.x+f.y*f.y),C=Math.sqrt(b.x*b.x+b.y*b.y),_={x:f.x/x,y:f.y/x},S={x:b.x/C,y:b.y/C},k={x:u.x+_.x*e,y:u.y+_.y*e},T={x:u.x+S.x*e,y:u.y+S.y*e};return d.push(`L ${k.x.toFixed(2)} ${k.y.toFixed(2)}`),d.push(`Q ${u.x.toFixed(2)} ${u.y.toFixed(2)} ${T.x.toFixed(2)} ${T.y.toFixed(2)}`),d.push("Z"),d.join(" ")}var Yr={xs:"xs",sm:13,md:20,lg:24,xl:40,xxl:"xxl"},Xr={xs:ie["size.xs"],sm:ie["size.sm"],md:ie["size.md"],lg:ie["size.lg"],xl:ie["size.xl"],xxl:ie["size.xxl"]},Jr={human:"user",agent:"settings"},W=class extends HTMLElement{static get observedAttributes(){return["type","size","src","alt","interactive","decorative","testid"]}constructor(){super(),this._shadowRoot=this.attachShadow({mode:"open"})}connectedCallback(){this.render()}attributeChangedCallback(i,e,t){e!==t&&this.isConnected&&this.render()}get type(){let i=this.getAttribute("type");return i==="human"||i==="agent"?i:bt.type}set type(i){this.setAttribute("type",i)}get size(){let i=this.getAttribute("size");return["xs","sm","md","lg","xl","xxl"].includes(i)?i:bt.size}set size(i){this.setAttribute("size",i)}get src(){return this.getAttribute("src")}set src(i){i?this.setAttribute("src",i):this.removeAttribute("src")}get alt(){return this.getAttribute("alt")}set alt(i){i?this.setAttribute("alt",i):this.removeAttribute("alt")}get interactive(){return this.getAttribute("interactive")==="true"}set interactive(i){i?this.setAttribute("interactive","true"):this.removeAttribute("interactive")}get decorative(){return this.getAttribute("decorative")==="true"}set decorative(i){i?this.setAttribute("decorative","true"):this.removeAttribute("decorative")}get testID(){return this.getAttribute("testid")}set testID(i){i?this.setAttribute("testid",i):this.removeAttribute("testid")}renderIconContent(i,e){let t=Jr[i],r=Yr[e];if(r==="xs"||r==="xxl"){let o=r==="xs"?"calc(var(--icon-size-050) * 0.75)":"calc(var(--icon-size-050) * 4)",a=this.getIconSVGContent(t);return`
|
|
339
339
|
<span class="avatar__icon avatar__icon--${i}" style="width: ${o}; height: ${o};">
|
|
340
340
|
<svg
|
|
341
341
|
viewBox="0 0 24 24"
|
|
@@ -421,7 +421,7 @@
|
|
|
421
421
|
${m}
|
|
422
422
|
</div>
|
|
423
423
|
</div>
|
|
424
|
-
`}attachImageErrorHandler(){let i=this._shadowRoot.querySelector(".avatar__image");i&&i.addEventListener("error",()=>this.handleImageError(),{once:!0})}};customElements.get("avatar-base")||customElements.define("avatar-base",
|
|
424
|
+
`}attachImageErrorHandler(){let i=this._shadowRoot.querySelector(".avatar__image");i&&i.addEventListener("error",()=>this.handleImageError(),{once:!0})}};customElements.get("avatar-base")||customElements.define("avatar-base",W);var mi={size:"md",truncate:!1},bi={sm:{typography:"typography.labelXs",paddingVertical:"space.inset.none",paddingHorizontal:"space.inset.050",iconSize:13,iconGap:"space.grouped.minimal"},md:{typography:"typography.labelSm",paddingVertical:"space.inset.050",paddingHorizontal:"space.inset.100",iconSize:20,iconGap:"space.grouped.tight"},lg:{typography:"typography.labelMd",paddingVertical:"space.inset.100",paddingHorizontal:"space.inset.150",iconSize:24,iconGap:"space.grouped.tight"}};var Qr=Q({component:"BadgeLabelBase",family:"spacing",tokens:{maxWidth:{value:v*15,reasoning:"Maximum width for truncated badges; allows ~12-15 characters before ellipsis while maintaining compact badge appearance. Value follows spacing family pattern (8 \xD7 15 = 120px) but exceeds standard spacing scale, requiring component-level definition."}}});function vi(){return Qr.maxWidth}var fi=".badge-label{display:inline-flex;align-items:center;box-sizing:border-box;border-radius:var(--radius-subtle);background-color:var(--color-structure-surface);color:var(--color-text-default);pointer-events:none;user-select:none;outline:none}.badge-label--sm{font-family:var(--typography-label-xs-font-family);font-size:var(--typography-label-xs-font-size);line-height:var(--typography-label-xs-line-height);font-weight:var(--typography-label-xs-font-weight);letter-spacing:var(--typography-label-xs-letter-spacing);padding-top:0;padding-bottom:0;padding-left:var(--space-050);padding-right:var(--space-050);gap:var(--space-025)}.badge-label--md{font-family:var(--typography-label-sm-font-family);font-size:var(--typography-label-sm-font-size);line-height:var(--typography-label-sm-line-height);font-weight:var(--typography-label-sm-font-weight);letter-spacing:var(--typography-label-sm-letter-spacing);padding-top:var(--space-050);padding-bottom:var(--space-050);padding-left:var(--space-100);padding-right:var(--space-100);gap:var(--space-050)}.badge-label--lg{font-family:var(--typography-label-md-font-family);font-size:var(--typography-label-md-font-size);line-height:var(--typography-label-md-line-height);font-weight:var(--typography-label-md-font-weight);letter-spacing:var(--typography-label-md-letter-spacing);padding-top:var(--space-100);padding-bottom:var(--space-100);padding-left:var(--space-150);padding-right:var(--space-150);gap:var(--space-050)}.badge-label__text{font:inherit;color:inherit;user-select:none}.badge-label__text--truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:var(--badgelabelbase-max-width,120px)}.badge-label__icon{flex-shrink:0;color:inherit;display:inline-flex;align-items:center;justify-content:center}@media (prefers-contrast:high){.badge-label{border:1px solid currentColor}}@media (prefers-reduced-motion:reduce){.badge-label{transition:none}}@media print{.badge-label{background-color:transparent;border:1px solid currentColor}}";var re=class extends HTMLElement{static get observedAttributes(){return["label","size","icon","truncate","test-id"]}constructor(){super(),this._shadowRoot=this.attachShadow({mode:"open"})}connectedCallback(){this.render()}attributeChangedCallback(i,e,t){e!==t&&this.isConnected&&this.render()}get label(){return this.getAttribute("label")||""}set label(i){this.setAttribute("label",i)}get size(){let i=this.getAttribute("size");return i==="sm"||i==="md"||i==="lg"?i:mi.size}set size(i){this.setAttribute("size",i)}get icon(){return this.getAttribute("icon")}set icon(i){i?this.setAttribute("icon",i):this.removeAttribute("icon")}get truncate(){return this.getAttribute("truncate")==="true"}set truncate(i){i?this.setAttribute("truncate","true"):this.removeAttribute("truncate")}get testID(){return this.getAttribute("test-id")}set testID(i){i?this.setAttribute("test-id",i):this.removeAttribute("test-id")}render(){let i=this.label,e=this.size,t=this.icon,r=this.truncate,s=this.testID,a=bi[e].iconSize,l=["badge-label",`badge-label--${e}`].join(" "),c=["badge-label__text",r?"badge-label__text--truncate":""].filter(Boolean).join(" "),d=s?` data-testid="${this.escapeHtml(s)}"`:"",h=r?` title="${this.escapeHtml(i)}"`:"",u=t?`
|
|
425
425
|
<span class="badge-label__icon" aria-hidden="true">
|
|
426
426
|
<icon-base name="${t}" size="${a}" color="inherit"></icon-base>
|
|
427
427
|
</span>
|
|
@@ -467,14 +467,14 @@
|
|
|
467
467
|
<span class="badge-count-notification__text">${this.escapeHtml(r)}</span>
|
|
468
468
|
${d}
|
|
469
469
|
</span>
|
|
470
|
-
`,this._previousCount=this.count}escapeHtml(e){let t={"&":"&","<":"<",">":">",'"':""","'":"'"};return e.replace(/[&<>"']/g,r=>t[r])}};customElements.get("badge-count-notification")||customElements.define("badge-count-notification",se);var xi=["checked","indeterminate","label","size","label-align","label-typography","helper-text","error-message","test-id","name","value"],tt={checked:!1,indeterminate:!1,size:"md",labelAlign:"center",labelTypography:"inherit"};var ki=":host{display:inline-block}.checkbox{display:inline-flex;align-items:center;position:relative}.checkbox__touch-target{display:inline-flex;align-items:center;cursor:pointer;user-select:none;min-height:var(--tap-area-recommended);box-sizing:border-box}.checkbox--align-top{align-items:flex-start}.checkbox--align-top .checkbox__touch-target{align-items:flex-start}.checkbox--sm .checkbox__touch-target{gap:var(--space-grouped-normal)}.checkbox--sm .checkbox__box{width:calc(var(--icon-size-050)+var(--space-inset-050) * 2);height:calc(var(--icon-size-050)+var(--space-inset-050) * 2);border-radius:var(--radius-subtle)}.checkbox--sm .checkbox__label{font-family:var(--typography-label-sm-font-family);font-size:var(--typography-label-sm-font-size);font-weight:var(--typography-label-sm-font-weight);line-height:var(--typography-label-sm-line-height);letter-spacing:var(--typography-label-sm-letter-spacing)}.checkbox--md .checkbox__touch-target{gap:var(--space-grouped-normal)}.checkbox--md .checkbox__box{width:calc(var(--icon-size-075)+var(--space-inset-075) * 2);height:calc(var(--icon-size-075)+var(--space-inset-075) * 2);border-radius:var(--radius-small)}.checkbox--md .checkbox__label{font-family:var(--typography-label-md-font-family);font-size:var(--typography-label-md-font-size);font-weight:var(--typography-label-md-font-weight);line-height:var(--typography-label-md-line-height);letter-spacing:var(--typography-label-md-letter-spacing)}.checkbox--lg .checkbox__touch-target{gap:var(--space-grouped-loose)}.checkbox--lg .checkbox__box{width:calc(var(--icon-size-100)+var(--space-inset-100) * 2);height:calc(var(--icon-size-100)+var(--space-inset-100) * 2);border-radius:var(--radius-small)}.checkbox--lg .checkbox__label{font-family:var(--typography-label-lg-font-family);font-size:var(--typography-label-lg-font-size);font-weight:var(--typography-label-lg-font-weight);line-height:var(--typography-label-lg-line-height);letter-spacing:var(--typography-label-lg-letter-spacing)}.checkbox--label-sm .checkbox__label{font-family:var(--typography-label-sm-font-family);font-size:var(--typography-label-sm-font-size);font-weight:var(--typography-label-sm-font-weight);line-height:var(--typography-label-sm-line-height);letter-spacing:var(--typography-label-sm-letter-spacing)}.checkbox--label-md .checkbox__label{font-family:var(--typography-label-md-font-family);font-size:var(--typography-label-md-font-size);font-weight:var(--typography-label-md-font-weight);line-height:var(--typography-label-md-line-height);letter-spacing:var(--typography-label-md-letter-spacing)}.checkbox--label-lg .checkbox__label{font-family:var(--typography-label-lg-font-family);font-size:var(--typography-label-lg-font-size);font-weight:var(--typography-label-lg-font-weight);line-height:var(--typography-label-lg-line-height);letter-spacing:var(--typography-label-lg-letter-spacing)}.checkbox__input{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.checkbox__box{flex-shrink:0;display:flex;align-items:center;justify-content:center;border:var(--border-emphasis) solid var(--color-feedback-select-border-default);background-color:transparent;transition:background-color var(--motion-selection-transition-duration) var(--motion-selection-transition-easing),border-color var(--motion-selection-transition-duration) var(--motion-selection-transition-easing);box-sizing:border-box}.checkbox__box icon-base{color:var(--color-contrast-on-light);display:flex}.checkbox--checked .checkbox__box{background-color:var(--color-feedback-select-background-rest);border-color:var(--color-feedback-select-border-rest)}.checkbox--indeterminate .checkbox__box{background-color:var(--color-feedback-select-background-rest);border-color:var(--color-feedback-select-border-rest)}.checkbox--error .checkbox__box{border-color:var(--color-feedback-error-border)}.checkbox__touch-target:hover .checkbox__box{border-color:var(--_checkbox-hover-border,var(--color-feedback-select-border-rest))}.checkbox--checked .checkbox__touch-target:hover .checkbox__box,.checkbox--indeterminate .checkbox__touch-target:hover .checkbox__box{border-color:var(--color-feedback-select-border-rest)}.checkbox-container{display:flex;flex-direction:column}.checkbox__content{display:flex;flex-direction:column;min-width:0}.checkbox__label{color:var(--color-text-default)}.checkbox__helper{display:block;margin-block-start:var(--space-grouped-minimal);margin-block-end:0;margin-inline:0;padding:0;font-family:var(--typography-caption-font-family);font-size:var(--typography-caption-font-size);line-height:var(--typography-caption-line-height);font-weight:var(--typography-caption-font-weight);letter-spacing:var(--typography-caption-letter-spacing);color:var(--color-text-muted)}.checkbox__error{display:block;margin-block-start:var(--space-grouped-minimal);margin-block-end:0;margin-inline:0;padding:0;font-family:var(--typography-caption-font-family);font-size:var(--typography-caption-font-size);line-height:var(--typography-caption-line-height);font-weight:var(--typography-caption-font-weight);letter-spacing:var(--typography-caption-letter-spacing);color:var(--color-feedback-error-text)}.checkbox__input:focus-visible~.checkbox__touch-target .checkbox__box{outline:var(--accessibility-focus-width) solid var(--accessibility-focus-color);outline-offset:var(--accessibility-focus-offset)}@media (prefers-contrast:high){.checkbox__box{border:var(--border-emphasis) solid currentColor}.checkbox__input:focus-visible~.checkbox__touch-target .checkbox__box{outline-width:var(--border-heavy)}}@media (prefers-reduced-motion:reduce){.checkbox__box{transition:none}}@media print{.checkbox__box{background-color:transparent !important;border-color:var(--color-print-default) !important}.checkbox__label{color:var(--color-print-default) !important}}";var en=0,Ci={sm:13,md:20,lg:24},oe=class extends HTMLElement{constructor(){super();this._input=null;this._form=null;this.onChange=null;this._hoverBorderColor="";this._onFormReset=()=>{this.checked=!1,this.indeterminate=!1,this._input&&(this._input.checked=!1,this._input.indeterminate=!1)};this._onInputChange=()=>{var t;if(!this._input)return;let e=this._input.checked;e?this.setAttribute("checked",""):this.removeAttribute("checked"),this.indeterminate&&this.removeAttribute("indeterminate"),(t=this.onChange)==null||t.call(this,e),this.dispatchEvent(new CustomEvent("change",{detail:{checked:e},bubbles:!0,composed:!0}))};this._shadowRoot=this.attachShadow({mode:"open"}),this._generatedId=`checkbox-${++en}`,this._blendUtils=E()}static get observedAttributes(){return[...xi]}connectedCallback(){this._calculateBlendColors(),this._attachToForm(),this.render(),this._attachListeners()}disconnectedCallback(){this._detachListeners(),this._detachFromForm()}attributeChangedCallback(e,t,r){t!==r&&this.isConnected&&(this.render(),this._attachListeners())}get checked(){return this.hasAttribute("checked")}set checked(e){e?this.setAttribute("checked",""):this.removeAttribute("checked")}get indeterminate(){return this.hasAttribute("indeterminate")}set indeterminate(e){e?this.setAttribute("indeterminate",""):this.removeAttribute("indeterminate")}get label(){return this.getAttribute("label")||""}set label(e){this.setAttribute("label",e)}get size(){let e=this.getAttribute("size");return e==="sm"||e==="md"||e==="lg"?e:tt.size}set size(e){this.setAttribute("size",e)}get labelAlign(){let e=this.getAttribute("label-align");return e==="center"||e==="top"?e:tt.labelAlign}set labelAlign(e){this.setAttribute("label-align",e)}get labelTypography(){let e=this.getAttribute("label-typography");return e==="inherit"||e==="sm"||e==="md"||e==="lg"?e:tt.labelTypography}set labelTypography(e){this.setAttribute("label-typography",e)}get helperText(){return this.getAttribute("helper-text")}set helperText(e){e?this.setAttribute("helper-text",e):this.removeAttribute("helper-text")}get errorMessage(){return this.getAttribute("error-message")}set errorMessage(e){e?this.setAttribute("error-message",e):this.removeAttribute("error-message")}get testID(){return this.getAttribute("test-id")}set testID(e){e?this.setAttribute("test-id",e):this.removeAttribute("test-id")}get name(){return this.getAttribute("name")}set name(e){e?this.setAttribute("name",e):this.removeAttribute("name")}get value(){return this.getAttribute("value")||"on"}set value(e){this.setAttribute("value",e)}_calculateBlendColors(){let t=getComputedStyle(document.documentElement).getPropertyValue("--color-feedback-select-border-default").trim();t&&(this._hoverBorderColor=this._blendUtils.hoverColor(t))}_attachToForm(){this._form=this.closest("form"),this._form&&this._form.addEventListener("reset",this._onFormReset)}_detachFromForm(){this._form&&(this._form.removeEventListener("reset",this._onFormReset),this._form=null)}render(){let e=this.getAttribute("id")||this._generatedId,t=`${e}-input`,r=`${e}-helper`,s=`${e}-error`,o=this.label,a=this.size,l=this.labelAlign,c=this.labelTypography,d=this.checked,h=this.indeterminate,u=this.helperText,m=this.errorMessage,g=!!m,f=this.testID,b=this.name,x=this.value,C=["checkbox",`checkbox--${a}`,l==="top"?"checkbox--align-top":"",c!=="inherit"?`checkbox--label-${c}`:"",d?"checkbox--checked":"",h?"checkbox--indeterminate":"",g?"checkbox--error":""].filter(Boolean).join(" "),_="";h?_=D({name:"minus",size:Ci[a],color:"inherit"}):d&&(_=D({name:"check",size:Ci[a],color:"inherit"}));let S=f?` data-testid="${f}"`:"",k=[];m&&k.push(s),u&&k.push(r);let T=k.length>0?` aria-describedby="${k.join(" ")}"`:"",w=u?`<span class="checkbox__helper" id="${r}">${u}</span>`:"",I=m?`<span class="checkbox__error" id="${s}" role="alert">${m}</span>`:"",Y=b?` name="${b}"`:"",H=`${e}-label`;this._shadowRoot.innerHTML=`
|
|
470
|
+
`,this._previousCount=this.count}escapeHtml(e){let t={"&":"&","<":"<",">":">",'"':""","'":"'"};return e.replace(/[&<>"']/g,r=>t[r])}};customElements.get("badge-count-notification")||customElements.define("badge-count-notification",se);var xi=["checked","indeterminate","label","size","label-align","label-typography","helper-text","error-message","test-id","name","value"],tt={checked:!1,indeterminate:!1,size:"md",labelAlign:"center",labelTypography:"inherit"};var ki=":host{display:inline-block}.checkbox{display:inline-flex;align-items:center;position:relative}.checkbox__touch-target{display:inline-flex;align-items:center;cursor:pointer;user-select:none;min-height:var(--tap-area-recommended);box-sizing:border-box}.checkbox--align-top{align-items:flex-start}.checkbox--align-top .checkbox__touch-target{align-items:flex-start}.checkbox--sm .checkbox__touch-target{gap:var(--space-grouped-normal)}.checkbox--sm .checkbox__box{width:calc(var(--icon-size-050)+var(--space-inset-050) * 2);height:calc(var(--icon-size-050)+var(--space-inset-050) * 2);border-radius:var(--radius-subtle)}.checkbox--sm .checkbox__label{font-family:var(--typography-label-sm-font-family);font-size:var(--typography-label-sm-font-size);font-weight:var(--typography-label-sm-font-weight);line-height:var(--typography-label-sm-line-height);letter-spacing:var(--typography-label-sm-letter-spacing)}.checkbox--md .checkbox__touch-target{gap:var(--space-grouped-normal)}.checkbox--md .checkbox__box{width:calc(var(--icon-size-075)+var(--space-inset-075) * 2);height:calc(var(--icon-size-075)+var(--space-inset-075) * 2);border-radius:var(--radius-small)}.checkbox--md .checkbox__label{font-family:var(--typography-label-md-font-family);font-size:var(--typography-label-md-font-size);font-weight:var(--typography-label-md-font-weight);line-height:var(--typography-label-md-line-height);letter-spacing:var(--typography-label-md-letter-spacing)}.checkbox--lg .checkbox__touch-target{gap:var(--space-grouped-loose)}.checkbox--lg .checkbox__box{width:calc(var(--icon-size-100)+var(--space-inset-100) * 2);height:calc(var(--icon-size-100)+var(--space-inset-100) * 2);border-radius:var(--radius-small)}.checkbox--lg .checkbox__label{font-family:var(--typography-label-lg-font-family);font-size:var(--typography-label-lg-font-size);font-weight:var(--typography-label-lg-font-weight);line-height:var(--typography-label-lg-line-height);letter-spacing:var(--typography-label-lg-letter-spacing)}.checkbox--label-sm .checkbox__label{font-family:var(--typography-label-sm-font-family);font-size:var(--typography-label-sm-font-size);font-weight:var(--typography-label-sm-font-weight);line-height:var(--typography-label-sm-line-height);letter-spacing:var(--typography-label-sm-letter-spacing)}.checkbox--label-md .checkbox__label{font-family:var(--typography-label-md-font-family);font-size:var(--typography-label-md-font-size);font-weight:var(--typography-label-md-font-weight);line-height:var(--typography-label-md-line-height);letter-spacing:var(--typography-label-md-letter-spacing)}.checkbox--label-lg .checkbox__label{font-family:var(--typography-label-lg-font-family);font-size:var(--typography-label-lg-font-size);font-weight:var(--typography-label-lg-font-weight);line-height:var(--typography-label-lg-line-height);letter-spacing:var(--typography-label-lg-letter-spacing)}.checkbox__input{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.checkbox__box{flex-shrink:0;display:flex;align-items:center;justify-content:center;border:var(--border-emphasis) solid var(--color-feedback-select-border-default);background-color:transparent;transition:background-color var(--motion-selection-transition-duration) var(--motion-selection-transition-easing),border-color var(--motion-selection-transition-duration) var(--motion-selection-transition-easing);box-sizing:border-box}.checkbox__box icon-base{color:var(--color-contrast-on-light);display:flex}.checkbox--checked .checkbox__box{background-color:var(--color-feedback-select-background-rest);border-color:var(--color-feedback-select-border-rest)}.checkbox--indeterminate .checkbox__box{background-color:var(--color-feedback-select-background-rest);border-color:var(--color-feedback-select-border-rest)}.checkbox--error .checkbox__box{border-color:var(--color-feedback-error-border)}.checkbox__touch-target:hover .checkbox__box{border-color:var(--_checkbox-hover-border,var(--color-feedback-select-border-rest))}.checkbox--checked .checkbox__touch-target:hover .checkbox__box,.checkbox--indeterminate .checkbox__touch-target:hover .checkbox__box{border-color:var(--color-feedback-select-border-rest)}.checkbox-container{display:flex;flex-direction:column}.checkbox__content{display:flex;flex-direction:column;min-width:0}.checkbox__label{color:var(--color-text-default)}.checkbox__helper{display:block;margin-block-start:var(--space-grouped-minimal);margin-block-end:0;margin-inline:0;padding:0;font-family:var(--typography-caption-font-family);font-size:var(--typography-caption-font-size);line-height:var(--typography-caption-line-height);font-weight:var(--typography-caption-font-weight);letter-spacing:var(--typography-caption-letter-spacing);color:var(--color-text-muted)}.checkbox__error{display:block;margin-block-start:var(--space-grouped-minimal);margin-block-end:0;margin-inline:0;padding:0;font-family:var(--typography-caption-font-family);font-size:var(--typography-caption-font-size);line-height:var(--typography-caption-line-height);font-weight:var(--typography-caption-font-weight);letter-spacing:var(--typography-caption-letter-spacing);color:var(--color-feedback-error-text)}.checkbox__input:focus-visible~.checkbox__touch-target .checkbox__box{outline:var(--accessibility-focus-width) solid var(--accessibility-focus-color);outline-offset:var(--accessibility-focus-offset)}@media (prefers-contrast:high){.checkbox__box{border:var(--border-emphasis) solid currentColor}.checkbox__input:focus-visible~.checkbox__touch-target .checkbox__box{outline-width:var(--border-heavy)}}@media (prefers-reduced-motion:reduce){.checkbox__box{transition:none}}@media print{.checkbox__box{background-color:transparent !important;border-color:var(--color-print-default) !important}.checkbox__label{color:var(--color-print-default) !important}}";var en=0,Ci={sm:13,md:20,lg:24},oe=class extends HTMLElement{constructor(){super();this._input=null;this._form=null;this.onChange=null;this._hoverBorderColor="";this._onFormReset=()=>{this.checked=!1,this.indeterminate=!1,this._input&&(this._input.checked=!1,this._input.indeterminate=!1)};this._onInputChange=()=>{var t;if(!this._input)return;let e=this._input.checked;e?this.setAttribute("checked",""):this.removeAttribute("checked"),this.indeterminate&&this.removeAttribute("indeterminate"),(t=this.onChange)==null||t.call(this,e),this.dispatchEvent(new CustomEvent("change",{detail:{checked:e},bubbles:!0,composed:!0}))};this._shadowRoot=this.attachShadow({mode:"open"}),this._generatedId=`checkbox-${++en}`,this._blendUtils=E()}static get observedAttributes(){return[...xi]}connectedCallback(){this._calculateBlendColors(),this._attachToForm(),this.render(),this._attachListeners()}disconnectedCallback(){this._detachListeners(),this._detachFromForm()}attributeChangedCallback(e,t,r){t!==r&&this.isConnected&&(this.render(),this._attachListeners())}get checked(){return this.hasAttribute("checked")}set checked(e){e?this.setAttribute("checked",""):this.removeAttribute("checked")}get indeterminate(){return this.hasAttribute("indeterminate")}set indeterminate(e){e?this.setAttribute("indeterminate",""):this.removeAttribute("indeterminate")}get label(){return this.getAttribute("label")||""}set label(e){this.setAttribute("label",e)}get size(){let e=this.getAttribute("size");return e==="sm"||e==="md"||e==="lg"?e:tt.size}set size(e){this.setAttribute("size",e)}get labelAlign(){let e=this.getAttribute("label-align");return e==="center"||e==="top"?e:tt.labelAlign}set labelAlign(e){this.setAttribute("label-align",e)}get labelTypography(){let e=this.getAttribute("label-typography");return e==="inherit"||e==="sm"||e==="md"||e==="lg"?e:tt.labelTypography}set labelTypography(e){this.setAttribute("label-typography",e)}get helperText(){return this.getAttribute("helper-text")}set helperText(e){e?this.setAttribute("helper-text",e):this.removeAttribute("helper-text")}get errorMessage(){return this.getAttribute("error-message")}set errorMessage(e){e?this.setAttribute("error-message",e):this.removeAttribute("error-message")}get testID(){return this.getAttribute("test-id")}set testID(e){e?this.setAttribute("test-id",e):this.removeAttribute("test-id")}get name(){return this.getAttribute("name")}set name(e){e?this.setAttribute("name",e):this.removeAttribute("name")}get value(){return this.getAttribute("value")||"on"}set value(e){this.setAttribute("value",e)}_calculateBlendColors(){let t=getComputedStyle(document.documentElement).getPropertyValue("--color-feedback-select-border-default").trim();t&&(this._hoverBorderColor=this._blendUtils.hoverColor(t))}_attachToForm(){this._form=this.closest("form"),this._form&&this._form.addEventListener("reset",this._onFormReset)}_detachFromForm(){this._form&&(this._form.removeEventListener("reset",this._onFormReset),this._form=null)}render(){let e=this.getAttribute("id")||this._generatedId,t=`${e}-input`,r=`${e}-helper`,s=`${e}-error`,o=this.label,a=this.size,l=this.labelAlign,c=this.labelTypography,d=this.checked,h=this.indeterminate,u=this.helperText,m=this.errorMessage,g=!!m,f=this.testID,b=this.name,x=this.value,C=["checkbox",`checkbox--${a}`,l==="top"?"checkbox--align-top":"",c!=="inherit"?`checkbox--label-${c}`:"",d?"checkbox--checked":"",h?"checkbox--indeterminate":"",g?"checkbox--error":""].filter(Boolean).join(" "),_="";h?_=D({name:"minus",size:Ci[a],color:"inherit"}):d&&(_=D({name:"check",size:Ci[a],color:"inherit"}));let S=f?` data-testid="${f}"`:"",k=[];m&&k.push(s),u&&k.push(r);let T=k.length>0?` aria-describedby="${k.join(" ")}"`:"",w=u?`<span class="checkbox__helper" id="${r}">${u}</span>`:"",I=m?`<span class="checkbox__error" id="${s}" role="alert">${m}</span>`:"",Z=b?` name="${b}"`:"",H=`${e}-label`;this._shadowRoot.innerHTML=`
|
|
471
471
|
<style>${ki}</style>
|
|
472
472
|
<div class="checkbox-container">
|
|
473
473
|
<div class="${C}"${S}>
|
|
474
474
|
<input
|
|
475
475
|
type="checkbox"
|
|
476
476
|
class="checkbox__input"
|
|
477
|
-
id="${t}"${
|
|
477
|
+
id="${t}"${Z}
|
|
478
478
|
value="${x}"
|
|
479
479
|
aria-labelledby="${H}"
|
|
480
480
|
${d?"checked":""}
|
|
@@ -628,7 +628,7 @@
|
|
|
628
628
|
<slot></slot>
|
|
629
629
|
</container-base>
|
|
630
630
|
</div>
|
|
631
|
-
`}};De.DEFAULTS={padding:"150",background:"surface.primary",shadow:"container",border:"none",borderColor:"border.default",borderRadius:"normal",semantic:"div",role:"button"};var
|
|
631
|
+
`}};De.DEFAULTS={padding:"150",background:"surface.primary",shadow:"container",border:"none",borderColor:"border.default",borderRadius:"normal",semantic:"div",role:"button"};var j=De;customElements.get("container-card-base")||customElements.define("container-card-base",j);var zi=["selected","label","value","name","size","label-align","helper-text","error-message","test-id"],yt={selected:!1,size:"md",labelAlign:"center"};var Ri=":host{display:inline-block}.radio-container{display:flex;flex-direction:column;gap:var(--space-grouped-tight)}.radio{display:inline-flex;align-items:center;position:relative}.radio__touch-target{display:inline-flex;align-items:center;cursor:pointer;user-select:none;min-height:var(--tap-area-recommended);box-sizing:border-box}.radio--align-center{align-items:center}.radio--align-center .radio__touch-target{align-items:center}.radio--align-top{align-items:flex-start}.radio--align-top .radio__touch-target{align-items:flex-start}.radio--sm .radio__touch-target{gap:var(--space-grouped-normal)}.radio--sm .radio__circle{width:calc(var(--icon-size-050)+var(--space-inset-050) * 2);height:calc(var(--icon-size-050)+var(--space-inset-050) * 2)}.radio--sm .radio__dot{width:var(--icon-size-050);height:var(--icon-size-050)}.radio--sm .radio__label{font-family:var(--typography-label-sm-font-family);font-size:var(--typography-label-sm-font-size);font-weight:var(--typography-label-sm-font-weight);line-height:var(--typography-label-sm-line-height);letter-spacing:var(--typography-label-sm-letter-spacing)}.radio--md .radio__touch-target{gap:var(--space-grouped-normal)}.radio--md .radio__circle{width:calc(var(--icon-size-075)+var(--space-inset-075) * 2);height:calc(var(--icon-size-075)+var(--space-inset-075) * 2)}.radio--md .radio__dot{width:var(--icon-size-075);height:var(--icon-size-075)}.radio--md .radio__label{font-family:var(--typography-label-md-font-family);font-size:var(--typography-label-md-font-size);font-weight:var(--typography-label-md-font-weight);line-height:var(--typography-label-md-line-height);letter-spacing:var(--typography-label-md-letter-spacing)}.radio--lg .radio__touch-target{gap:var(--space-grouped-loose)}.radio--lg .radio__circle{width:calc(var(--icon-size-100)+var(--space-inset-100) * 2);height:calc(var(--icon-size-100)+var(--space-inset-100) * 2)}.radio--lg .radio__dot{width:var(--icon-size-100);height:var(--icon-size-100)}.radio--lg .radio__label{font-family:var(--typography-label-lg-font-family);font-size:var(--typography-label-lg-font-size);font-weight:var(--typography-label-lg-font-weight);line-height:var(--typography-label-lg-line-height);letter-spacing:var(--typography-label-lg-letter-spacing)}.radio__input{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}.radio__circle{flex-shrink:0;display:flex;align-items:center;justify-content:center;border:var(--border-emphasis) solid var(--color-feedback-select-border-default);border-radius:var(--radius-full);background-color:transparent;transition:border-color var(--motion-selection-transition-duration) var(--motion-selection-transition-easing);box-sizing:border-box}.radio__dot{border-radius:var(--radius-full);background-color:var(--color-feedback-select-background-rest);transform:scale(0);transition:transform var(--motion-selection-transition-duration) var(--motion-selection-transition-easing)}.radio--selected .radio__circle{border-color:var(--color-feedback-select-border-rest)}.radio--selected .radio__dot{transform:scale(1)}.radio--error .radio__circle{border-color:var(--color-feedback-error-border)}.radio__touch-target:hover .radio__circle{border-color:var(--_radio-hover-border,var(--color-feedback-select-border-rest))}.radio--selected .radio__touch-target:hover .radio__circle{border-color:var(--color-feedback-select-border-rest)}.radio__input:focus-visible~.radio__touch-target .radio__circle{outline:var(--accessibility-focus-width) solid var(--accessibility-focus-color);outline-offset:var(--accessibility-focus-offset)}.radio__content{display:flex;flex-direction:column;min-width:0}.radio__label{color:var(--color-text-default)}.radio__helper{display:block;margin-block-start:var(--space-grouped-minimal);margin-block-end:0;margin-inline:0;padding:0;font-family:var(--typography-caption-font-family);font-size:var(--typography-caption-font-size);line-height:var(--typography-caption-line-height);font-weight:var(--typography-caption-font-weight);letter-spacing:var(--typography-caption-letter-spacing);color:var(--color-text-muted)}.radio__error{display:block;margin-block-start:var(--space-grouped-minimal);margin-block-end:0;margin-inline:0;padding:0;font-family:var(--typography-caption-font-family);font-size:var(--typography-caption-font-size);line-height:var(--typography-caption-line-height);font-weight:var(--typography-caption-font-weight);letter-spacing:var(--typography-caption-letter-spacing);color:var(--color-feedback-error-text)}@media (prefers-contrast:high){.radio__circle{border:var(--border-emphasis) solid currentColor}.radio__input:focus-visible~.radio__touch-target .radio__circle{outline-width:var(--border-heavy)}}@media (prefers-reduced-motion:reduce){.radio__circle,.radio__dot{transition:none}}@media print{.radio__circle{background-color:transparent !important;border-color:var(--color-print-default) !important}.radio__dot{background-color:var(--color-print-default) !important}.radio__label{color:var(--color-print-default) !important}}";var on=0,K=class extends HTMLElement{constructor(){super();this._input=null;this._form=null;this.onSelect=null;this._hoverBorderColor="";this._onFormReset=()=>{this.selected=!1,this._input&&(this._input.checked=!1),this._updateFormValue()};this._onInputChange=()=>{var t;if(!this._input)return;let e=this._input.checked;e?this.setAttribute("selected",""):this.removeAttribute("selected"),this._updateFormValue(),e&&((t=this.onSelect)==null||t.call(this,this.value)),this.dispatchEvent(new CustomEvent("select",{detail:{value:this.value,selected:e},bubbles:!0,composed:!0}))};this._shadowRoot=this.attachShadow({mode:"open"}),this._generatedId=`radio-${++on}`,this._internals=this.attachInternals(),this._blendUtils=E()}static get observedAttributes(){return[...zi]}connectedCallback(){this._calculateBlendColors(),this._attachToForm(),this.render(),this._attachListeners(),this._updateFormValue()}disconnectedCallback(){this._detachListeners(),this._detachFromForm()}attributeChangedCallback(e,t,r){t!==r&&this.isConnected&&(this.render(),this._attachListeners(),(e==="selected"||e==="value"||e==="name")&&this._updateFormValue())}get selected(){return this.hasAttribute("selected")}set selected(e){e?this.setAttribute("selected",""):this.removeAttribute("selected")}get label(){return this.getAttribute("label")||""}set label(e){this.setAttribute("label",e)}get value(){return this.getAttribute("value")||""}set value(e){this.setAttribute("value",e)}get name(){return this.getAttribute("name")}set name(e){e?this.setAttribute("name",e):this.removeAttribute("name")}get size(){let e=this.getAttribute("size");return e==="sm"||e==="md"||e==="lg"?e:yt.size}set size(e){this.setAttribute("size",e)}get labelAlign(){let e=this.getAttribute("label-align");return e==="center"||e==="top"?e:yt.labelAlign}set labelAlign(e){this.setAttribute("label-align",e)}get helperText(){return this.getAttribute("helper-text")}set helperText(e){e?this.setAttribute("helper-text",e):this.removeAttribute("helper-text")}get errorMessage(){return this.getAttribute("error-message")}set errorMessage(e){e?this.setAttribute("error-message",e):this.removeAttribute("error-message")}get testID(){return this.getAttribute("test-id")}set testID(e){e?this.setAttribute("test-id",e):this.removeAttribute("test-id")}_calculateBlendColors(){let t=getComputedStyle(document.documentElement).getPropertyValue("--color-feedback-select-border-default").trim();t&&(this._hoverBorderColor=this._blendUtils.hoverColor(t))}_updateFormValue(){var s;if(typeof((s=this._internals)==null?void 0:s.setFormValue)!="function")return;let e=this.name,t=this.value,r=this.selected;e&&r?this._internals.setFormValue(t):this._internals.setFormValue(null)}_attachToForm(){this._form=this.closest("form"),this._form&&this._form.addEventListener("reset",this._onFormReset)}_detachFromForm(){this._form&&(this._form.removeEventListener("reset",this._onFormReset),this._form=null)}render(){let e=this.getAttribute("id")||this._generatedId,t=`${e}-input`,r=`${e}-helper`,s=`${e}-error`,o=this.label,a=this.size,l=this.labelAlign,c=this.selected,d=this.helperText,h=this.errorMessage,u=!!h,m=this.testID,g=this.name,f=this.value,b=["radio",`radio--${a}`,l==="top"?"radio--align-top":"",c?"radio--selected":"",u?"radio--error":""].filter(Boolean).join(" "),x=m?` data-testid="${m}"`:"",C=[];h&&C.push(s),d&&C.push(r);let _=C.length>0?` aria-describedby="${C.join(" ")}"`:"",S=d?`<span class="radio__helper" id="${r}">${d}</span>`:"",k=h?`<span class="radio__error" id="${s}" role="alert">${h}</span>`:"",T=g?` name="${g}"`:"",w=`${e}-label`;this._shadowRoot.innerHTML=`
|
|
632
632
|
<style>${Ri}</style>
|
|
633
633
|
<div class="radio-container">
|
|
634
634
|
<div class="${b}"${x}>
|
|
@@ -654,7 +654,7 @@
|
|
|
654
654
|
${S}
|
|
655
655
|
${k}
|
|
656
656
|
</div>
|
|
657
|
-
`,this._input=this._shadowRoot.querySelector(".radio__input"),this._input&&(this._input.checked=c);let I=this._shadowRoot.querySelector(".radio");I&&this._hoverBorderColor&&I.style.setProperty("--_radio-hover-border",this._hoverBorderColor)}_attachListeners(){var e;(e=this._input)==null||e.addEventListener("change",this._onInputChange)}_detachListeners(){var e;(e=this._input)==null||e.removeEventListener("change",this._onInputChange)}};
|
|
657
|
+
`,this._input=this._shadowRoot.querySelector(".radio__input"),this._input&&(this._input.checked=c);let I=this._shadowRoot.querySelector(".radio");I&&this._hoverBorderColor&&I.style.setProperty("--_radio-hover-border",this._hoverBorderColor)}_attachListeners(){var e;(e=this._input)==null||e.addEventListener("change",this._onInputChange)}_detachListeners(){var e;(e=this._input)==null||e.removeEventListener("change",this._onInputChange)}};K.formAssociated=!0;customElements.get("input-radio-base")||customElements.define("input-radio-base",K);var Bi=["selected-value","required","error","error-message","size","test-id"],xt={selectedValue:null,required:!1,error:!1,size:"md"};var Li=":host{display:block}.radio-set{display:flex;flex-direction:column;gap:var(--space-grouped-normal)}.radio-set__error{display:none;margin-block:0;margin-inline:0;padding:0;font-family:var(--typography-caption-font-family);font-size:var(--typography-caption-font-size);line-height:var(--typography-caption-line-height);font-weight:var(--typography-caption-font-weight);letter-spacing:var(--typography-caption-letter-spacing);color:var(--color-feedback-error-text)}.radio-set--error .radio-set__error{display:block}@media (prefers-reduced-motion:reduce){.radio-set{transition:none}}@media print{.radio-set__error{color:var(--color-print-default) !important}}";var an=0,ue=class extends HTMLElement{constructor(){super();this._container=null;this._errorMessageEl=null;this.onSelectionChange=null;this._focusedIndex=0;this._onChildSelect=this._handleChildSelect.bind(this);this._handleKeyDown=e=>{let t=this._getChildRadios(),r=t.length;if(r===0)return;let s=this._processKeyboardNavigation(e,r);s.handled&&(e.preventDefault(),s.newFocusIndex!==this._focusedIndex&&this._moveFocusToIndex(s.newFocusIndex,t),s.shouldSelect&&this._selectRadioAtIndex(this._focusedIndex,t))};this._handleFocusIn=e=>{let r=e.target.closest("input-radio-base");if(!r)return;let s=this._getChildRadios(),o=s.indexOf(r);o!==-1&&o!==this._focusedIndex&&(this._focusedIndex=o,this._updateTabIndices(s,o))};this._shadowRoot=this.attachShadow({mode:"open",delegatesFocus:!0}),this._errorMessageId=`radio-set-error-${++an}`}static get observedAttributes(){return[...Bi]}connectedCallback(){this._createDOM(),this.addEventListener("select",this._onChildSelect),this.addEventListener("keydown",this._handleKeyDown),this.addEventListener("focusin",this._handleFocusIn),this._syncChildrenSelection(),this._initializeTabIndices()}disconnectedCallback(){this.removeEventListener("select",this._onChildSelect),this.removeEventListener("keydown",this._handleKeyDown),this.removeEventListener("focusin",this._handleFocusIn)}attributeChangedCallback(e,t,r){t!==r&&this.isConnected&&(this._updateDOM(),(e==="selected-value"||e==="size")&&this._syncChildrenSelection(),e==="selected-value"&&this._initializeTabIndices())}get selectedValue(){var e;return(e=this.getAttribute("selected-value"))!=null?e:xt.selectedValue}set selectedValue(e){e!==null?this.setAttribute("selected-value",e):this.removeAttribute("selected-value")}get required(){return this.hasAttribute("required")}set required(e){e?this.setAttribute("required",""):this.removeAttribute("required")}get error(){return this.hasAttribute("error")}set error(e){e?this.setAttribute("error",""):this.removeAttribute("error")}get errorMessage(){return this.getAttribute("error-message")}set errorMessage(e){e?this.setAttribute("error-message",e):this.removeAttribute("error-message")}get size(){let e=this.getAttribute("size");return e==="sm"||e==="md"||e==="lg"?e:xt.size}set size(e){this.setAttribute("size",e)}get testID(){return this.getAttribute("test-id")}validate(){return this.required&&(this.selectedValue===null||this.selectedValue==="")?(this.error=!0,this.errorMessage||(this.errorMessage="Please select an option"),!1):(this.error=!1,!0)}checkValidity(){return!(this.required&&(this.selectedValue===null||this.selectedValue===""))}set testID(e){e?this.setAttribute("test-id",e):this.removeAttribute("test-id")}_createDOM(){let e=this.testID,t=e?` data-testid="${e}"`:"";this._shadowRoot.innerHTML=`
|
|
658
658
|
<style>${Li}</style>
|
|
659
659
|
<div
|
|
660
660
|
class="radio-set"
|
|
@@ -698,5 +698,5 @@
|
|
|
698
698
|
<slot name="leading" slot="leading"></slot>
|
|
699
699
|
<slot name="center" slot="title"></slot>
|
|
700
700
|
<slot name="trailing" slot="trailing"></slot>
|
|
701
|
-
`,this._shadowRoot.appendChild(i)}};customElements.get("nav-header-app")||customElements.define("nav-header-app",xe);var sr=".nav-header-page__title{font-family:var(--typography-label-md-font-family);font-size:var(--typography-label-md-font-size);font-weight:var(--typography-label-md-font-weight);line-height:var(--typography-label-md-line-height);letter-spacing:var(--typography-label-md-letter-spacing);color:var(--color-action-navigation);margin:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.nav-header-page__title-wrapper--center{position:absolute;inset-inline:0;display:flex;justify-content:center;pointer-events:none}.nav-header-page__title-wrapper--center .nav-header-page__title{max-inline-size:60%;text-align:center}.nav-header-page__title-wrapper--leading{flex:1;min-inline-size:0}.nav-header-page__trailing{display:flex;align-items:center;gap:var(--space-grouped-minimal);flex-shrink:0}.nav-header-page__close-gap{inline-size:var(--space-grouped-tight)}:host{transition:transform var(--duration-150) var(--easing-standard)}:host(.nav-header-page--hidden){transform:translateY(-100%)}@media (prefers-reduced-motion:reduce){:host{transition:none !important;transform:none !important}}:host(.nav-header-page--android-padding) .nav-header__content{padding-block:var(--space-inset-100)}";var or=8,ke=class extends HTMLElement{constructor(){super();this._domCreated=!1;this._lastScrollY=0;this._hidden=!1;this._scrollHandler=null;this._shadowRoot=this.attachShadow({mode:"open"})}connectedCallback(){this._domCreated||(this._createDOM(),this._domCreated=!0),this._setupScroll()}disconnectedCallback(){this._teardownScroll()}static get observedAttributes(){return["title","title-alignment","scroll-behavior","appearance","show-separator","test-id"]}attributeChangedCallback(){this._domCreated&&(this._updateTitle(),this._updateAlignment(),this._setupScroll())}_createDOM(){var h;let e=document.createElement("style");e.textContent=sr;let t=document.createElement("nav-header");t.setAttribute("appearance",this.getAttribute("appearance")||"opaque"),t.setAttribute("show-separator",(h=this.getAttribute("show-separator"))!=null?h:"true"),this.getAttribute("test-id")&&t.setAttribute("test-id",this.getAttribute("test-id"));let r=document.createElement("div");r.setAttribute("slot","leading"),r.innerHTML='<slot name="leading-action"></slot>';let s=document.createElement("div");s.setAttribute("slot","title");let o=this._getAlignment();s.className=`nav-header-page__title-wrapper--${o}`;let a=document.createElement("h1");a.className="nav-header-page__title",a.textContent=this.getAttribute("title")||"",s.appendChild(a);let l=document.createElement("div");l.setAttribute("slot","trailing"),l.className="nav-header-page__trailing",l.innerHTML='<slot name="trailing-actions"></slot>';let c=document.createElement("slot");c.name="close-action";let d=document.createElement("span");d.className="nav-header-page__close-gap",l.appendChild(d),l.appendChild(c),t.appendChild(r),t.appendChild(s),t.appendChild(l),this._shadowRoot.appendChild(e),this._shadowRoot.appendChild(t)}_getAlignment(){let e=this.getAttribute("title-alignment");return e||"leading"}_updateTitle(){let e=this._shadowRoot.querySelector(".nav-header-page__title");e&&(e.textContent=this.getAttribute("title")||"")}_updateAlignment(){let e=this._shadowRoot.querySelector('[slot="title"]');if(!e)return;let t=this._getAlignment();e.className=`nav-header-page__title-wrapper--${t}`}_setupScroll(){this._teardownScroll(),this.getAttribute("scroll-behavior")==="collapsible"&&(window.matchMedia("(prefers-reduced-motion: reduce)").matches||(this._lastScrollY=window.scrollY,this._scrollHandler=()=>this._onScroll(),window.addEventListener("scroll",this._scrollHandler,{passive:!0})))}_teardownScroll(){this._scrollHandler&&(window.removeEventListener("scroll",this._scrollHandler),this._scrollHandler=null)}_onScroll(){let e=window.scrollY,t=e-this._lastScrollY;t>or&&!this._hidden?(this._hidden=!0,this.classList.add("nav-header-page--hidden")):t<-or&&this._hidden&&(this._hidden=!1,this.classList.remove("nav-header-page--hidden")),this._lastScrollY=e}};customElements.get("nav-header-page")||customElements.define("nav-header-page",ke);var ar=":host{display:block;inline-size:100%}.progress-bar{position:relative;inline-size:100%;border-radius:var(--radius-full);background-color:var(--color-progress-pending-background);overflow:hidden}.progress-bar--sm{block-size:var(--size-050)}.progress-bar--md{block-size:var(--size-100)}.progress-bar--lg{block-size:var(--size-150)}.progress-bar__fill{position:absolute;inset-block:0;inset-inline-start:0;border-radius:var(--radius-full);transition:inline-size var(--duration-150) var(--easing-standard)}.progress-bar__fill--determinate{background-color:var(--color-progress-completed-background)}.progress-bar__fill--indeterminate{background-color:var(--color-progress-current-background);inline-size:33%;animation:pulse var(--duration-350) var(--easing-standard) infinite alternate}@keyframes pulse{from{opacity:0.3}to{opacity:1}}@media (prefers-reduced-motion:reduce){.progress-bar__fill{transition:none !important;animation:none !important}}";var gn=[0,25,50,75,100],Ce=class extends HTMLElement{constructor(){super();this._domCreated=!1;this._lastAnnouncedMilestone=-1;this._shadowRoot=this.attachShadow({mode:"open"})}connectedCallback(){this._domCreated||(this._createDOM(),this._domCreated=!0),this._update()}static get observedAttributes(){return["value","mode","size","accessibility-label","test-id"]}attributeChangedCallback(){this._domCreated&&this._update()}_createDOM(){let e=document.createElement("style");e.textContent=ar;let t=document.createElement("div");t.classList.add("progress-bar"),t.setAttribute("role","progressbar"),t.setAttribute("aria-valuemin","0"),t.setAttribute("aria-valuemax","1");let r=document.createElement("div");r.classList.add("progress-bar__fill"),t.appendChild(r),this._shadowRoot.appendChild(e),this._shadowRoot.appendChild(t)}_update(){let e=this._shadowRoot.querySelector(".progress-bar"),t=this._shadowRoot.querySelector(".progress-bar__fill");if(!e||!t)return;let r=this.getAttribute("mode")||"determinate",s=this.getAttribute("size")||"md",o=this.getAttribute("accessibility-label")||"",a=this.getAttribute("test-id");if(e.className=`progress-bar progress-bar--${s}`,e.setAttribute("aria-label",o),a&&e.setAttribute("data-testid",a),r==="indeterminate")t.className="progress-bar__fill progress-bar__fill--indeterminate",t.style.inlineSize="",e.removeAttribute("aria-valuenow"),window.matchMedia("(prefers-reduced-motion: reduce)").matches&&(t.style.inlineSize=`${.33*100}%`,t.style.opacity="1");else{let l=this.getAttribute("value");if(l===null)throw new Error("Progress-Bar-Base: value attribute is required in determinate mode");let c=parseFloat(l);this._validateValue(c),t.className="progress-bar__fill progress-bar__fill--determinate",t.style.inlineSize=`${c*100}%`,t.style.opacity="",e.setAttribute("aria-valuenow",String(c)),this._announceMilestone(c)}}_validateValue(e){if(e<0||e>1)throw new Error(`Progress-Bar-Base: value must be between 0 and 1, received ${e}`)}_announceMilestone(e){let t=Math.round(e*100);for(let r of gn)if(t>=r&&this._lastAnnouncedMilestone<r){this._lastAnnouncedMilestone=r;let s=this._shadowRoot.querySelector(".progress-bar");s&&(s.setAttribute("aria-live","polite"),setTimeout(()=>s.removeAttribute("aria-live"),100))}}};customElements.get("progress-bar")||customElements.define("progress-bar",Ce);function lr(){let n=getComputedStyle(document.documentElement).getPropertyValue("--color-action-primary");(!n||n.trim()==="")&&console.warn('[DesignerPunk] Design tokens not detected. Include tokens.css before using components: <link rel="stylesheet" href="dist/browser/tokens.css">')}function y(n,i){customElements.get(n)||customElements.define(n,i)}y("input-text-base",
|
|
701
|
+
`,this._shadowRoot.appendChild(i)}};customElements.get("nav-header-app")||customElements.define("nav-header-app",xe);var sr=".nav-header-page__title{font-family:var(--typography-label-md-font-family);font-size:var(--typography-label-md-font-size);font-weight:var(--typography-label-md-font-weight);line-height:var(--typography-label-md-line-height);letter-spacing:var(--typography-label-md-letter-spacing);color:var(--color-action-navigation);margin:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.nav-header-page__title-wrapper--center{position:absolute;inset-inline:0;display:flex;justify-content:center;pointer-events:none}.nav-header-page__title-wrapper--center .nav-header-page__title{max-inline-size:60%;text-align:center}.nav-header-page__title-wrapper--leading{flex:1;min-inline-size:0}.nav-header-page__trailing{display:flex;align-items:center;gap:var(--space-grouped-minimal);flex-shrink:0}.nav-header-page__close-gap{inline-size:var(--space-grouped-tight)}:host{transition:transform var(--duration-150) var(--easing-standard)}:host(.nav-header-page--hidden){transform:translateY(-100%)}@media (prefers-reduced-motion:reduce){:host{transition:none !important;transform:none !important}}:host(.nav-header-page--android-padding) .nav-header__content{padding-block:var(--space-inset-100)}";var or=8,ke=class extends HTMLElement{constructor(){super();this._domCreated=!1;this._lastScrollY=0;this._hidden=!1;this._scrollHandler=null;this._shadowRoot=this.attachShadow({mode:"open"})}connectedCallback(){this._domCreated||(this._createDOM(),this._domCreated=!0),this._setupScroll()}disconnectedCallback(){this._teardownScroll()}static get observedAttributes(){return["title","title-alignment","scroll-behavior","appearance","show-separator","test-id"]}attributeChangedCallback(){this._domCreated&&(this._updateTitle(),this._updateAlignment(),this._setupScroll())}_createDOM(){var h;let e=document.createElement("style");e.textContent=sr;let t=document.createElement("nav-header");t.setAttribute("appearance",this.getAttribute("appearance")||"opaque"),t.setAttribute("show-separator",(h=this.getAttribute("show-separator"))!=null?h:"true"),this.getAttribute("test-id")&&t.setAttribute("test-id",this.getAttribute("test-id"));let r=document.createElement("div");r.setAttribute("slot","leading"),r.innerHTML='<slot name="leading-action"></slot>';let s=document.createElement("div");s.setAttribute("slot","title");let o=this._getAlignment();s.className=`nav-header-page__title-wrapper--${o}`;let a=document.createElement("h1");a.className="nav-header-page__title",a.textContent=this.getAttribute("title")||"",s.appendChild(a);let l=document.createElement("div");l.setAttribute("slot","trailing"),l.className="nav-header-page__trailing",l.innerHTML='<slot name="trailing-actions"></slot>';let c=document.createElement("slot");c.name="close-action";let d=document.createElement("span");d.className="nav-header-page__close-gap",l.appendChild(d),l.appendChild(c),t.appendChild(r),t.appendChild(s),t.appendChild(l),this._shadowRoot.appendChild(e),this._shadowRoot.appendChild(t)}_getAlignment(){let e=this.getAttribute("title-alignment");return e||"leading"}_updateTitle(){let e=this._shadowRoot.querySelector(".nav-header-page__title");e&&(e.textContent=this.getAttribute("title")||"")}_updateAlignment(){let e=this._shadowRoot.querySelector('[slot="title"]');if(!e)return;let t=this._getAlignment();e.className=`nav-header-page__title-wrapper--${t}`}_setupScroll(){this._teardownScroll(),this.getAttribute("scroll-behavior")==="collapsible"&&(window.matchMedia("(prefers-reduced-motion: reduce)").matches||(this._lastScrollY=window.scrollY,this._scrollHandler=()=>this._onScroll(),window.addEventListener("scroll",this._scrollHandler,{passive:!0})))}_teardownScroll(){this._scrollHandler&&(window.removeEventListener("scroll",this._scrollHandler),this._scrollHandler=null)}_onScroll(){let e=window.scrollY,t=e-this._lastScrollY;t>or&&!this._hidden?(this._hidden=!0,this.classList.add("nav-header-page--hidden")):t<-or&&this._hidden&&(this._hidden=!1,this.classList.remove("nav-header-page--hidden")),this._lastScrollY=e}};customElements.get("nav-header-page")||customElements.define("nav-header-page",ke);var ar=":host{display:block;inline-size:100%}.progress-bar{position:relative;inline-size:100%;border-radius:var(--radius-full);background-color:var(--color-progress-pending-background);overflow:hidden}.progress-bar--sm{block-size:var(--size-050)}.progress-bar--md{block-size:var(--size-100)}.progress-bar--lg{block-size:var(--size-150)}.progress-bar__fill{position:absolute;inset-block:0;inset-inline-start:0;border-radius:var(--radius-full);transition:inline-size var(--duration-150) var(--easing-standard)}.progress-bar__fill--determinate{background-color:var(--color-progress-completed-background)}.progress-bar__fill--indeterminate{background-color:var(--color-progress-current-background);inline-size:33%;animation:pulse var(--duration-350) var(--easing-standard) infinite alternate}@keyframes pulse{from{opacity:0.3}to{opacity:1}}@media (prefers-reduced-motion:reduce){.progress-bar__fill{transition:none !important;animation:none !important}}";var gn=[0,25,50,75,100],Ce=class extends HTMLElement{constructor(){super();this._domCreated=!1;this._lastAnnouncedMilestone=-1;this._shadowRoot=this.attachShadow({mode:"open"})}connectedCallback(){this._domCreated||(this._createDOM(),this._domCreated=!0),this._update()}static get observedAttributes(){return["value","mode","size","accessibility-label","test-id"]}attributeChangedCallback(){this._domCreated&&this._update()}_createDOM(){let e=document.createElement("style");e.textContent=ar;let t=document.createElement("div");t.classList.add("progress-bar"),t.setAttribute("role","progressbar"),t.setAttribute("aria-valuemin","0"),t.setAttribute("aria-valuemax","1");let r=document.createElement("div");r.classList.add("progress-bar__fill"),t.appendChild(r),this._shadowRoot.appendChild(e),this._shadowRoot.appendChild(t)}_update(){let e=this._shadowRoot.querySelector(".progress-bar"),t=this._shadowRoot.querySelector(".progress-bar__fill");if(!e||!t)return;let r=this.getAttribute("mode")||"determinate",s=this.getAttribute("size")||"md",o=this.getAttribute("accessibility-label")||"",a=this.getAttribute("test-id");if(e.className=`progress-bar progress-bar--${s}`,e.setAttribute("aria-label",o),a&&e.setAttribute("data-testid",a),r==="indeterminate")t.className="progress-bar__fill progress-bar__fill--indeterminate",t.style.inlineSize="",e.removeAttribute("aria-valuenow"),window.matchMedia("(prefers-reduced-motion: reduce)").matches&&(t.style.inlineSize=`${.33*100}%`,t.style.opacity="1");else{let l=this.getAttribute("value");if(l===null)throw new Error("Progress-Bar-Base: value attribute is required in determinate mode");let c=parseFloat(l);this._validateValue(c),t.className="progress-bar__fill progress-bar__fill--determinate",t.style.inlineSize=`${c*100}%`,t.style.opacity="",e.setAttribute("aria-valuenow",String(c)),this._announceMilestone(c)}}_validateValue(e){if(e<0||e>1)throw new Error(`Progress-Bar-Base: value must be between 0 and 1, received ${e}`)}_announceMilestone(e){let t=Math.round(e*100);for(let r of gn)if(t>=r&&this._lastAnnouncedMilestone<r){this._lastAnnouncedMilestone=r;let s=this._shadowRoot.querySelector(".progress-bar");s&&(s.setAttribute("aria-live","polite"),setTimeout(()=>s.removeAttribute("aria-live"),100))}}};customElements.get("progress-bar")||customElements.define("progress-bar",Ce);function lr(){let n=getComputedStyle(document.documentElement).getPropertyValue("--color-action-primary");(!n||n.trim()==="")&&console.warn('[DesignerPunk] Design tokens not detected. Include tokens.css before using components: <link rel="stylesheet" href="dist/browser/tokens.css">')}function y(n,i){customElements.get(n)||customElements.define(n,i)}y("input-text-base",J);y("input-text-email",Ee);y("input-text-password",we);y("input-text-phone-number",Ie);y("button-cta",ze);y("icon-base",O);y("button-icon",Re);y("container-base",q);y("button-vertical-list-item",ee);y("button-vertical-list-set",te);y("avatar-base",W);y("badge-label-base",re);y("badge-count-base",ne);y("badge-count-notification",se);y("input-checkbox-base",oe);y("input-checkbox-legal",ae);y("chip-base",le);y("chip-filter",ce);y("chip-input",de);y("container-card-base",j);y("input-radio-base",K);y("input-radio-set",ue);y("progress-indicator-node-base",he);y("progress-indicator-connector-base",pe);y("progress-indicator-label-base",ge);y("progress-pagination-base",me);y("progress-stepper-base",be);y("progress-stepper-detailed",ve);y("nav-segmented-choice",fe);y("nav-tab-bar",_e);y("nav-header",ye);y("nav-header-app",xe);y("nav-header-page",ke);y("progress-bar",Ce);typeof document!="undefined"&&(document.readyState==="loading"?document.addEventListener("DOMContentLoaded",()=>{requestAnimationFrame(()=>lr())}):requestAnimationFrame(()=>lr()));var mn=O,bn=O,vn=q,fn=q,_n=ee,yn=te,xn=W,kn=W,Cn=re,Sn=ne,En=se,wn=oe,An=ae,Tn=J,In=le,zn=ce,Rn=de,Bn=j,Ln=j,Vn=K,$n=ue,Pn=he,Mn=pe,Dn=ge,Nn=me,Hn=be,On=ve,Fn=fe,Un=_e,qn=ye,Gn=xe,Wn=ke,jn=Ce;return br(Kn);})();
|
|
702
702
|
//# sourceMappingURL=designerpunk.umd.min.js.map
|