@adam-milo/ui 1.0.72 → 1.0.74
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index13.cjs +1 -1
- package/dist/index13.js +3 -3
- package/dist/index48.cjs +1 -1
- package/dist/index48.js +2 -2
- package/dist/src/components/forms/select/Select.component.d.ts.map +1 -1
- package/dist/src/components/typography/heading/Heading.component.d.ts.map +1 -1
- package/dist/src/components/typography/heading/Heading.types.d.ts +2 -0
- package/dist/src/components/typography/heading/Heading.types.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/index13.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),t=require("react"),r=require("@radix-ui/react-select"),a=require("./index52.cjs"),s=require("./index64.cjs");function l(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e)for(const r in e)if("default"!==r){const a=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,a.get?a:{enumerable:!0,get:()=>e[r]})}return t.default=e,Object.freeze(t)}const c=l(r),i=c.Root,d=t.forwardRef(({className:r,children:l,label:i,error:d,helperText:o,fullWidth:n=!1,hasValue:p=!1,placeholder:
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),t=require("react"),r=require("@radix-ui/react-select"),a=require("./index52.cjs"),s=require("./index64.cjs");function l(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e)for(const r in e)if("default"!==r){const a=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,a.get?a:{enumerable:!0,get:()=>e[r]})}return t.default=e,Object.freeze(t)}const c=l(r),i=c.Root,d=t.forwardRef(({className:r,children:l,label:i,error:d,helperText:o,fullWidth:n=!1,hasValue:p=!1,placeholder:u,id:g,"data-cy":y,"data-testid":S,disabled:h,required:m,...x},b)=>{const f=t.useId(),j=g||f,N=`${j}-label`,$=`${j}-error`,w=`${j}-helper`,v=y||"select-trigger",L=S||"select-trigger",q=i&&m&&!i.includes("*")?`${i} *`:i;return e.jsxs("div",{className:a.cn(s.triggerWrapperStyles,n&&s.triggerWrapperFullWidthStyles),"data-cy":`${v}-wrapper`,"data-testid":`${L}-wrapper`,children:[i&&e.jsx("label",{id:N,htmlFor:j,className:a.cn(s.triggerLabelStyles,d&&s.triggerLabelErrorStyles,h&&s.triggerLabelDisabledStyles),"data-cy":`${v}-label`,"data-testid":`${L}-label`,children:q}),e.jsxs(c.Trigger,{ref:b,id:j,className:a.cn(s.triggerButtonStyles,d&&s.triggerButtonErrorStyles,!p&&s.triggerButtonPlaceholderStyles,r),"aria-invalid":d?"true":"false","aria-describedby":d?$:o?w:void 0,"aria-labelledby":i?N:void 0,"aria-required":m?"true":void 0,"data-cy":v,"data-testid":L,disabled:h,...x,children:[e.jsx("span",{className:s.triggerValueStyles,children:p?l:e.jsx("span",{"data-cy":`${v}-placeholder`,"data-testid":`${L}-placeholder`,children:u||i})}),e.jsx(c.Icon,{className:s.triggerIconStyles,"data-cy":`${v}-icon`,"data-testid":`${L}-icon`,children:e.jsx("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:e.jsx("path",{d:"M5 7.5L10 12.5L15 7.5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})})]}),d&&e.jsx("span",{id:$,className:s.triggerErrorStyles,role:"alert","data-cy":`${v}-error`,"data-testid":`${L}-error`,children:d}),o&&!d&&e.jsx("span",{id:w,className:s.triggerHelperStyles,"data-cy":`${v}-helper`,"data-testid":`${L}-helper`,children:o})]})});d.displayName="SelectTrigger";const o=c.Value,n=t.forwardRef(({className:t,children:r,position:l="popper","data-cy":i,"data-testid":d,...o},n)=>{const p=i||"select-content",u=d||"select-content";return e.jsx(c.Portal,{children:e.jsx(c.Content,{ref:n,className:a.cn(s.contentStyles,t),position:l,sideOffset:0,"data-cy":p,"data-testid":u,...o,children:e.jsx(c.Viewport,{className:s.viewportStyles,children:r})})})});n.displayName="SelectContent";const p=t.forwardRef(({className:t,children:r,value:l,"data-cy":i,"data-testid":d,...o},n)=>{const p=i||`select-item-${l}`,u=d||`select-item-${l}`;return e.jsx(c.Item,{ref:n,className:a.cn(s.itemStyles,t),value:l,"data-cy":p,"data-testid":u,...o,children:e.jsx(c.ItemText,{children:r})})});p.displayName="SelectItem";const u=c.Group,g=t.forwardRef(({className:t,"data-cy":r,"data-testid":l,...i},d)=>{const o=r||"select-label",n=l||"select-label";return e.jsx(c.Label,{ref:d,className:a.cn(s.labelStyles,t),"data-cy":o,"data-testid":n,...i})});g.displayName="SelectLabel";const y=t.forwardRef(({className:t,"data-cy":r,"data-testid":l,...i},d)=>{const o=r||"select-separator",n=l||"select-separator";return e.jsx(c.Separator,{ref:d,className:a.cn(s.separatorStyles,t),"data-cy":o,"data-testid":n,...i})});y.displayName="SelectSeparator",exports.Select=i,exports.SelectContent=n,exports.SelectGroup=u,exports.SelectItem=p,exports.SelectLabel=g,exports.SelectSeparator=y,exports.SelectTrigger=d,exports.SelectValue=o;
|
package/dist/index13.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import{jsx as e,jsxs as a}from"react/jsx-runtime";import{forwardRef as t,useId as r}from"react";import*as d from"@radix-ui/react-select";import{cn as l}from"./index52.js";import{viewportStyles as s,triggerValueStyles as i,triggerIconStyles as c,triggerErrorStyles as o,triggerHelperStyles as n,triggerLabelDisabledStyles as m,triggerLabelErrorStyles as p,triggerLabelStyles as h,triggerButtonPlaceholderStyles as y,triggerButtonErrorStyles as
|
|
2
|
-
return a("div",{className:l(b,w&&$),"data-cy":`${M}-wrapper`,"data-testid":`${O}-wrapper`,children:[f&&/* @__PURE__ */e("label",{id:B,htmlFor:W,className:l(h,g&&p,I&&m),"data-cy":`${M}-label`,"data-testid":`${O}-label`,children:
|
|
3
|
-
/* @__PURE__ */a(d.Trigger,{ref:V,id:W,className:l(
|
|
1
|
+
import{jsx as e,jsxs as a}from"react/jsx-runtime";import{forwardRef as t,useId as r}from"react";import*as d from"@radix-ui/react-select";import{cn as l}from"./index52.js";import{viewportStyles as s,triggerValueStyles as i,triggerIconStyles as c,triggerErrorStyles as o,triggerHelperStyles as n,triggerLabelDisabledStyles as m,triggerLabelErrorStyles as p,triggerLabelStyles as h,triggerButtonPlaceholderStyles as y,triggerButtonErrorStyles as u,triggerButtonStyles as N,triggerWrapperFullWidthStyles as $,triggerWrapperStyles as b,contentStyles as f,itemStyles as g,labelStyles as v,separatorStyles as w}from"./index64.js";const x=d.Root,S=t(({className:t,children:s,label:f,error:g,helperText:v,fullWidth:w=!1,hasValue:x=!1,placeholder:S,id:L,"data-cy":j,"data-testid":k,disabled:I,required:T,...C},V)=>{const q=r(),W=L||q,B=`${W}-label`,F=`${W}-error`,G=`${W}-helper`,M=j||"select-trigger",O=k||"select-trigger",P=f&&T&&!f.includes("*")?`${f} *`:f;/* @__PURE__ */
|
|
2
|
+
return a("div",{className:l(b,w&&$),"data-cy":`${M}-wrapper`,"data-testid":`${O}-wrapper`,children:[f&&/* @__PURE__ */e("label",{id:B,htmlFor:W,className:l(h,g&&p,I&&m),"data-cy":`${M}-label`,"data-testid":`${O}-label`,children:P}),
|
|
3
|
+
/* @__PURE__ */a(d.Trigger,{ref:V,id:W,className:l(N,g&&u,!x&&y,t),"aria-invalid":g?"true":"false","aria-describedby":g?F:v?G:void 0,"aria-labelledby":f?B:void 0,"aria-required":T?"true":void 0,"data-cy":M,"data-testid":O,disabled:I,...C,children:[
|
|
4
4
|
/* @__PURE__ */e("span",{className:i,children:x?s:/* @__PURE__ */e("span",{"data-cy":`${M}-placeholder`,"data-testid":`${O}-placeholder`,children:S||f})}),
|
|
5
5
|
/* @__PURE__ */e(d.Icon,{className:c,"data-cy":`${M}-icon`,"data-testid":`${O}-icon`,children:/* @__PURE__ */e("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",children:/* @__PURE__ */e("path",{d:"M5 7.5L10 12.5L15 7.5",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})})})]}),g&&/* @__PURE__ */e("span",{id:F,className:o,role:"alert","data-cy":`${M}-error`,"data-testid":`${O}-error`,children:g}),v&&!g&&/* @__PURE__ */e("span",{id:G,className:n,"data-cy":`${M}-helper`,"data-testid":`${O}-helper`,children:v})]})});S.displayName="SelectTrigger";const L=d.Value,j=t(({className:a,children:t,position:r="popper","data-cy":i,"data-testid":c,...o},n)=>{const m=i||"select-content",p=c||"select-content";/* @__PURE__ */
|
|
6
6
|
return e(d.Portal,{children:/* @__PURE__ */e(d.Content,{ref:n,className:l(f,a),position:r,sideOffset:0,"data-cy":m,"data-testid":p,...o,children:/* @__PURE__ */e(d.Viewport,{className:s,children:t})})})});j.displayName="SelectContent";const k=t(({className:a,children:t,value:r,"data-cy":s,"data-testid":i,...c},o)=>{const n=s||`select-item-${r}`,m=i||`select-item-${r}`;/* @__PURE__ */
|
package/dist/index48.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),t=require("react"),r=require("./index52.cjs"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),t=require("react"),r=require("./index52.cjs"),i=require("./index91.cjs"),s=t.forwardRef(({level:t=2,size:s,weight:a="bold",color:l="text",align:d="start",className:n="",required:c,"data-cy":o,"data-testid":g,children:u,...y},h)=>{const x=s??i.levelToSizeMap[t],S=o||`heading-h${t}-${x}`,j=g||`heading-h${t}-${x}`,m=c?"string"==typeof u?u.includes("*")?u:`${u} *`:e.jsxs(e.Fragment,{children:[u," *"]}):u,p=r.cn(i.rootStyles,i.sizeStyles[x],i.weightStyles[a],i.colorStyles[l],i.alignStyles[d],n),$=`h${t}`;return e.jsx($,{ref:h,className:p,"data-cy":S,"data-testid":j,...y,children:m})});s.displayName="Heading",exports.Heading=s;
|
package/dist/index48.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{jsx as
|
|
2
|
-
return
|
|
1
|
+
import{jsxs as e,Fragment as t,jsx as r}from"react/jsx-runtime";import{forwardRef as i}from"react";import{cn as a}from"./index52.js";import{levelToSizeMap as d,alignStyles as s,colorStyles as n,weightStyles as o,sizeStyles as c,rootStyles as l}from"./index91.js";const m=i(({level:i=2,size:m,weight:h="bold",color:p="text",align:f="start",className:g="",required:$,"data-cy":x,"data-testid":u,children:y,...j},N)=>{const b=m??d[i],q=x||`heading-h${i}-${b}`,v=u||`heading-h${i}-${b}`,w=$?"string"==typeof y?y.includes("*")?y:`${y} *`/* @__PURE__ */:e(t,{children:[y," *"]}):y,z=a(l,c[b],o[h],n[p],s[f],g);/* @__PURE__ */
|
|
2
|
+
return r(`h${i}`,{ref:N,className:z,"data-cy":q,"data-testid":v,...j,children:w})});m.displayName="Heading";export{m as Heading};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Select.component.d.ts","sourceRoot":"","sources":["../../../../../src/components/forms/select/Select.component.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,eAAe,MAAM,wBAAwB,CAAC;AAE1D,OAAO,KAAK,EACV,kBAAkB,EAClB,kBAAkB,EAClB,eAAe,EACf,gBAAgB,EAChB,oBAAoB,EACrB,MAAM,gBAAgB,CAAC;AAqBxB,eAAO,MAAM,MAAM,iDAAuB,CAAC;AAE3C,eAAO,MAAM,aAAa,
|
|
1
|
+
{"version":3,"file":"Select.component.d.ts","sourceRoot":"","sources":["../../../../../src/components/forms/select/Select.component.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,eAAe,MAAM,wBAAwB,CAAC;AAE1D,OAAO,KAAK,EACV,kBAAkB,EAClB,kBAAkB,EAClB,eAAe,EACf,gBAAgB,EAChB,oBAAoB,EACrB,MAAM,gBAAgB,CAAC;AAqBxB,eAAO,MAAM,MAAM,iDAAuB,CAAC;AAE3C,eAAO,MAAM,aAAa,kHAuIzB,CAAC;AAGF,eAAO,MAAM,WAAW,8HAAwB,CAAC;AAEjD,eAAO,MAAM,aAAa,+GAkCzB,CAAC;AAGF,eAAO,MAAM,UAAU,4GAkBtB,CAAC;AAGF,eAAO,MAAM,WAAW,6HAAwB,CAAC;AAEjD,eAAO,MAAM,WAAW,6GAevB,CAAC;AAGF,eAAO,MAAM,eAAe,iHAgB1B,CAAC;AAGH,YAAY,EACV,kBAAkB,EAClB,kBAAkB,EAClB,eAAe,EACf,gBAAgB,EAChB,oBAAoB,GACrB,MAAM,gBAAgB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Heading.component.d.ts","sourceRoot":"","sources":["../../../../../src/components/typography/heading/Heading.component.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAUpD,eAAO,MAAM,OAAO,
|
|
1
|
+
{"version":3,"file":"Heading.component.d.ts","sourceRoot":"","sources":["../../../../../src/components/typography/heading/Heading.component.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAUpD,eAAO,MAAM,OAAO,6GA0DnB,CAAC;AAIF,YAAY,EACV,YAAY,EACZ,YAAY,EACZ,WAAW,EACX,aAAa,EACb,YAAY,EACZ,YAAY,GACb,MAAM,iBAAiB,CAAC"}
|
|
@@ -11,6 +11,8 @@ export interface HeadingProps extends Omit<ComponentPropsWithoutRef<'h1'>, 'colo
|
|
|
11
11
|
weight?: HeadingWeight;
|
|
12
12
|
color?: HeadingColor;
|
|
13
13
|
align?: HeadingAlign;
|
|
14
|
+
/** When true, appends * to heading text (for required field labels). */
|
|
15
|
+
required?: boolean;
|
|
14
16
|
className?: string;
|
|
15
17
|
'data-cy'?: string;
|
|
16
18
|
'data-testid'?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Heading.types.d.ts","sourceRoot":"","sources":["../../../../../src/components/typography/heading/Heading.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,OAAO,CAAC;AAEtD,MAAM,MAAM,YAAY,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;AACjD,MAAM,MAAM,WAAW,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,KAAK,GAAG,KAAK,CAAC;AAC3E,MAAM,MAAM,aAAa,GAAG,QAAQ,GAAG,UAAU,GAAG,MAAM,GAAG,OAAO,CAAC;AACrE,MAAM,MAAM,YAAY,GAAG,OAAO,GAAG,QAAQ,GAAG,KAAK,GAAG,YAAY,CAAC;AACrE,MAAM,MAAM,YAAY,GACpB,MAAM,GACN,QAAQ,GACR,WAAW,GACX,OAAO,GACP,OAAO,GACP,WAAW,GACX,aAAa,GACb,SAAS,CAAC;AAEd,MAAM,WAAW,YAAa,SAAQ,IAAI,CAAC,wBAAwB,CAAC,IAAI,CAAC,EAAE,OAAO,CAAC;IACjF,KAAK,CAAC,EAAE,YAAY,CAAC;IACrB,IAAI,CAAC,EAAE,WAAW,CAAC;IACnB,MAAM,CAAC,EAAE,aAAa,CAAC;IACvB,KAAK,CAAC,EAAE,YAAY,CAAC;IACrB,KAAK,CAAC,EAAE,YAAY,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAC5B"}
|
|
1
|
+
{"version":3,"file":"Heading.types.d.ts","sourceRoot":"","sources":["../../../../../src/components/typography/heading/Heading.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,OAAO,CAAC;AAEtD,MAAM,MAAM,YAAY,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;AACjD,MAAM,MAAM,WAAW,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,KAAK,GAAG,KAAK,CAAC;AAC3E,MAAM,MAAM,aAAa,GAAG,QAAQ,GAAG,UAAU,GAAG,MAAM,GAAG,OAAO,CAAC;AACrE,MAAM,MAAM,YAAY,GAAG,OAAO,GAAG,QAAQ,GAAG,KAAK,GAAG,YAAY,CAAC;AACrE,MAAM,MAAM,YAAY,GACpB,MAAM,GACN,QAAQ,GACR,WAAW,GACX,OAAO,GACP,OAAO,GACP,WAAW,GACX,aAAa,GACb,SAAS,CAAC;AAEd,MAAM,WAAW,YAAa,SAAQ,IAAI,CAAC,wBAAwB,CAAC,IAAI,CAAC,EAAE,OAAO,CAAC;IACjF,KAAK,CAAC,EAAE,YAAY,CAAC;IACrB,IAAI,CAAC,EAAE,WAAW,CAAC;IACnB,MAAM,CAAC,EAAE,aAAa,CAAC;IACvB,KAAK,CAAC,EAAE,YAAY,CAAC;IACrB,KAAK,CAAC,EAAE,YAAY,CAAC;IACrB,wEAAwE;IACxE,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAC5B"}
|