@scbt-ecom/ui 0.139.3 → 0.140.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.
@@ -1,2 +1,2 @@
1
- import{jsx as a}from"react/jsx-runtime";import{cva as n}from"../../../../../node_modules/class-variance-authority/dist/index.js";import{cn as l}from"../../../utils/cn.js";import"react";const m=n("desk-body-regular-m mt-2",{variants:{intent:{simple:"text-color-tetriary text-center",error:"text-color-negative text-center"},disabled:{true:"text-color-disabled",false:""}},defaultVariants:{intent:"simple"}}),u=({intent:t,as:r="p",disabled:i,text:e,className:o,...s})=>e?a(r,{className:l(m({intent:t,disabled:i}),o),...s,children:e}):null;export{u as MessageView};
1
+ import{jsx as a}from"react/jsx-runtime";import{cva as n}from"../../../../../node_modules/class-variance-authority/dist/index.js";import{cn as l}from"../../../utils/cn.js";import"react";const m=n("desk-body-regular-m mt-2",{variants:{intent:{simple:"text-color-tetriary",error:"text-color-negative"},disabled:{true:"text-color-disabled",false:""}},defaultVariants:{intent:"simple"}}),u=({intent:r,as:t="p",disabled:i,text:e,className:o,...s})=>e?a(t,{className:l(m({intent:r,disabled:i}),o),...s,children:e}):null;export{u as MessageView};
2
2
  //# sourceMappingURL=MessageView.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"MessageView.js","sources":["../../../../../../lib/shared/ui/formElements/ui/MessageView.tsx"],"sourcesContent":["'use client'\n\nimport { type ReactElement } from 'react'\nimport type { FieldError } from 'react-hook-form'\nimport { cva, type VariantProps } from 'class-variance-authority'\nimport { cn } from '$/shared/utils'\n\nconst messageViewConfig = cva('desk-body-regular-m mt-2', {\n variants: {\n intent: {\n simple: 'text-color-tetriary text-center',\n error: 'text-color-negative text-center'\n },\n disabled: {\n true: 'text-color-disabled',\n false: ''\n }\n },\n defaultVariants: {\n intent: 'simple'\n }\n})\n\nexport interface IMessageViewProps extends VariantProps<typeof messageViewConfig> {\n as?: 'div' | 'span' | 'p'\n text?: string | FieldError['message'] | ReactElement\n className?: string\n}\n\nexport const MessageView = ({ intent, as: Element = 'p', disabled, text, className, ...props }: IMessageViewProps) => {\n if (!text) return null\n\n return (\n <Element className={cn(messageViewConfig({ intent, disabled }), className)} {...props}>\n {text}\n </Element>\n )\n}\n"],"names":["messageViewConfig","cva","MessageView","intent","Element","disabled","text","className","props","jsx","cn"],"mappings":"yLAOA,MAAMA,EAAoBC,EAAI,2BAA4B,CACxD,SAAU,CACR,OAAQ,CACN,OAAQ,kCACR,MAAO,iCAAA,EAET,SAAU,CACR,KAAM,sBACN,MAAO,EAAA,CACT,EAEF,gBAAiB,CACf,OAAQ,QAAA,CAEZ,CAAC,EAQYC,EAAc,CAAC,CAAE,OAAAC,EAAQ,GAAIC,EAAU,IAAK,SAAAC,EAAU,KAAAC,EAAM,UAAAC,EAAW,GAAGC,CAAA,IAChFF,EAGHG,EAACL,EAAA,CAAQ,UAAWM,EAAGV,EAAkB,CAAE,OAAAG,EAAQ,SAAAE,CAAA,CAAU,EAAGE,CAAS,EAAI,GAAGC,EAC7E,SAAAF,EACH,EALgB"}
1
+ {"version":3,"file":"MessageView.js","sources":["../../../../../../lib/shared/ui/formElements/ui/MessageView.tsx"],"sourcesContent":["'use client'\n\nimport { type ReactElement } from 'react'\nimport type { FieldError } from 'react-hook-form'\nimport { cva, type VariantProps } from 'class-variance-authority'\nimport { cn } from '$/shared/utils'\n\nconst messageViewConfig = cva('desk-body-regular-m mt-2', {\n variants: {\n intent: {\n simple: 'text-color-tetriary',\n error: 'text-color-negative'\n },\n disabled: {\n true: 'text-color-disabled',\n false: ''\n }\n },\n defaultVariants: {\n intent: 'simple'\n }\n})\n\nexport interface IMessageViewProps extends VariantProps<typeof messageViewConfig> {\n as?: 'div' | 'span' | 'p'\n text?: string | FieldError['message'] | ReactElement\n className?: string\n}\n\nexport const MessageView = ({ intent, as: Element = 'p', disabled, text, className, ...props }: IMessageViewProps) => {\n if (!text) return null\n\n return (\n <Element className={cn(messageViewConfig({ intent, disabled }), className)} {...props}>\n {text}\n </Element>\n )\n}\n"],"names":["messageViewConfig","cva","MessageView","intent","Element","disabled","text","className","props","jsx","cn"],"mappings":"yLAOA,MAAMA,EAAoBC,EAAI,2BAA4B,CACxD,SAAU,CACR,OAAQ,CACN,OAAQ,sBACR,MAAO,qBAAA,EAET,SAAU,CACR,KAAM,sBACN,MAAO,EAAA,CACT,EAEF,gBAAiB,CACf,OAAQ,QAAA,CAEZ,CAAC,EAQYC,EAAc,CAAC,CAAE,OAAAC,EAAQ,GAAIC,EAAU,IAAK,SAAAC,EAAU,KAAAC,EAAM,UAAAC,EAAW,GAAGC,CAAA,IAChFF,EAGHG,EAACL,EAAA,CAAQ,UAAWM,EAAGV,EAAkB,CAAE,OAAAG,EAAQ,SAAAE,CAAA,CAAU,EAAGE,CAAS,EAAI,GAAGC,EAC7E,SAAAF,EACH,EALgB"}