@stokelp/ui 2.117.2 → 2.119.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/index.d.ts +1 -0
- package/dist/components/steps/Steps.cjs +2 -0
- package/dist/components/steps/Steps.cjs.map +1 -0
- package/dist/components/steps/Steps.d.ts +26 -0
- package/dist/components/steps/Steps.js +11 -0
- package/dist/components/steps/Steps.js.map +1 -0
- package/dist/components/steps/index.d.ts +1 -0
- package/dist/components/supplier-rating-badge/SupplierRatingBreakdown.cjs +1 -1
- package/dist/components/supplier-rating-badge/SupplierRatingBreakdown.cjs.map +1 -1
- package/dist/components/supplier-rating-badge/SupplierRatingBreakdown.d.ts +1 -1
- package/dist/components/supplier-rating-badge/SupplierRatingBreakdown.js +6 -6
- package/dist/components/supplier-rating-badge/SupplierRatingBreakdown.js.map +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +56 -55
- package/dist/theme/recipes/combobox.cjs +1 -1
- package/dist/theme/recipes/combobox.cjs.map +1 -1
- package/dist/theme/recipes/combobox.js +2 -1
- package/dist/theme/recipes/combobox.js.map +1 -1
- package/dist/theme/recipes/index.cjs +1 -1
- package/dist/theme/recipes/index.cjs.map +1 -1
- package/dist/theme/recipes/index.d.ts +1 -0
- package/dist/theme/recipes/index.js +101 -99
- package/dist/theme/recipes/index.js.map +1 -1
- package/dist/theme/recipes/steps.cjs +2 -0
- package/dist/theme/recipes/steps.cjs.map +1 -0
- package/dist/theme/recipes/steps.d.ts +2 -0
- package/dist/theme/recipes/steps.js +100 -0
- package/dist/theme/recipes/steps.js.map +1 -0
- package/dist/ui.css +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use client";const e=require("../../utils/slots.cjs");let t=require("@ark-ui/react"),n=require("@stokelp/styled-system/jsx"),r=require("@stokelp/styled-system/recipes");var{withProvider:i,withContext:a}=e.createStyleContext(r.steps),o=i((0,n.styled)(t.Steps.Root),`root`),s=a((0,n.styled)(t.Steps.List),`list`),c=a((0,n.styled)(t.Steps.Item),`item`),l=a((0,n.styled)(t.Steps.Trigger),`trigger`),u=a((0,n.styled)(t.Steps.Indicator),`indicator`),d=a((0,n.styled)(t.Steps.Separator),`separator`),f=a((0,n.styled)(t.Steps.Content),`content`);exports.Steps=o,exports.StepsContent=f,exports.StepsIndicator=u,exports.StepsItem=c,exports.StepsList=s,exports.StepsSeparator=d,exports.StepsTrigger=l;
|
|
2
|
+
//# sourceMappingURL=Steps.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Steps.cjs","names":[],"sources":["../../../src/components/steps/Steps.tsx"],"sourcesContent":["import { Steps as ArkSteps } from '@ark-ui/react'\nimport { ComponentProps } from 'react'\nimport { styled } from '@stokelp/styled-system/jsx'\nimport { steps } from '@stokelp/styled-system/recipes'\nimport { createStyleContext } from '~/utils/slots.tsx'\n\nconst { withProvider, withContext } = createStyleContext(steps)\n\nexport const Steps = withProvider(styled(ArkSteps.Root), 'root')\nexport const StepsList = withContext(styled(ArkSteps.List), 'list')\nexport const StepsItem = withContext(styled(ArkSteps.Item), 'item')\nexport const StepsTrigger = withContext(styled(ArkSteps.Trigger), 'trigger')\nexport const StepsIndicator = withContext(styled(ArkSteps.Indicator), 'indicator')\nexport const StepsSeparator = withContext(styled(ArkSteps.Separator), 'separator')\nexport const StepsContent = withContext(styled(ArkSteps.Content), 'content')\n\nexport interface StepsProps extends ComponentProps<typeof Steps> {}\n\nexport interface StepsListProps extends ComponentProps<typeof StepsList> {}\n\nexport interface StepsItemProps extends ComponentProps<typeof StepsItem> {}\n\nexport interface StepsTriggerProps extends ComponentProps<typeof StepsTrigger> {}\n\nexport interface StepsIndicatorProps extends ComponentProps<typeof StepsIndicator> {}\n\nexport interface StepsSeparatorProps extends ComponentProps<typeof StepsSeparator> {}\n\nexport interface StepsContentProps extends ComponentProps<typeof StepsContent> {}\n"],"mappings":"yKAMA,GAAM,CAAE,eAAc,eAAgB,EAAA,mBAAmB,EAAA,KAAK,EAEjD,EAAQ,GAAA,EAAA,EAAA,QAAoB,EAAA,MAAS,IAAI,EAAG,MAAM,EAClD,EAAY,GAAA,EAAA,EAAA,QAAmB,EAAA,MAAS,IAAI,EAAG,MAAM,EACrD,EAAY,GAAA,EAAA,EAAA,QAAmB,EAAA,MAAS,IAAI,EAAG,MAAM,EACrD,EAAe,GAAA,EAAA,EAAA,QAAmB,EAAA,MAAS,OAAO,EAAG,SAAS,EAC9D,EAAiB,GAAA,EAAA,EAAA,QAAmB,EAAA,MAAS,SAAS,EAAG,WAAW,EACpE,EAAiB,GAAA,EAAA,EAAA,QAAmB,EAAA,MAAS,SAAS,EAAG,WAAW,EACpE,EAAe,GAAA,EAAA,EAAA,QAAmB,EAAA,MAAS,OAAO,EAAG,SAAS"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { Steps as ArkSteps } from '@ark-ui/react';
|
|
2
|
+
import { ComponentProps, ForwardRefExoticComponent, RefAttributes } from 'react';
|
|
3
|
+
import { ComponentVariants } from '../../utils/slots.tsx';
|
|
4
|
+
import { StyledComponent } from '@stokelp/styled-system/types';
|
|
5
|
+
import { StepsRecipe } from '@stokelp/styled-system/recipes';
|
|
6
|
+
export declare const Steps: ComponentVariants<StyledComponent<ForwardRefExoticComponent<ArkSteps.RootProps & RefAttributes<HTMLDivElement>>, {}>, StepsRecipe>;
|
|
7
|
+
export declare const StepsList: StyledComponent<ForwardRefExoticComponent<ArkSteps.ListProps & RefAttributes<HTMLDivElement>>, {}>;
|
|
8
|
+
export declare const StepsItem: StyledComponent<ForwardRefExoticComponent<ArkSteps.ItemProps & RefAttributes<HTMLDivElement>>, {}>;
|
|
9
|
+
export declare const StepsTrigger: StyledComponent<ForwardRefExoticComponent<ArkSteps.TriggerProps & RefAttributes<HTMLButtonElement>>, {}>;
|
|
10
|
+
export declare const StepsIndicator: StyledComponent<ForwardRefExoticComponent<ArkSteps.IndicatorProps & RefAttributes<HTMLDivElement>>, {}>;
|
|
11
|
+
export declare const StepsSeparator: StyledComponent<ForwardRefExoticComponent<ArkSteps.SeparatorProps & RefAttributes<HTMLDivElement>>, {}>;
|
|
12
|
+
export declare const StepsContent: StyledComponent<ForwardRefExoticComponent<ArkSteps.ContentProps & RefAttributes<HTMLDivElement>>, {}>;
|
|
13
|
+
export interface StepsProps extends ComponentProps<typeof Steps> {
|
|
14
|
+
}
|
|
15
|
+
export interface StepsListProps extends ComponentProps<typeof StepsList> {
|
|
16
|
+
}
|
|
17
|
+
export interface StepsItemProps extends ComponentProps<typeof StepsItem> {
|
|
18
|
+
}
|
|
19
|
+
export interface StepsTriggerProps extends ComponentProps<typeof StepsTrigger> {
|
|
20
|
+
}
|
|
21
|
+
export interface StepsIndicatorProps extends ComponentProps<typeof StepsIndicator> {
|
|
22
|
+
}
|
|
23
|
+
export interface StepsSeparatorProps extends ComponentProps<typeof StepsSeparator> {
|
|
24
|
+
}
|
|
25
|
+
export interface StepsContentProps extends ComponentProps<typeof StepsContent> {
|
|
26
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { createStyleContext as e } from "../../utils/slots.js";
|
|
3
|
+
import { Steps as t } from "@ark-ui/react";
|
|
4
|
+
import { styled as n } from "@stokelp/styled-system/jsx";
|
|
5
|
+
import { steps as r } from "@stokelp/styled-system/recipes";
|
|
6
|
+
//#region src/components/steps/Steps.tsx
|
|
7
|
+
var { withProvider: i, withContext: a } = e(r), o = i(n(t.Root), "root"), s = a(n(t.List), "list"), c = a(n(t.Item), "item"), l = a(n(t.Trigger), "trigger"), u = a(n(t.Indicator), "indicator"), d = a(n(t.Separator), "separator"), f = a(n(t.Content), "content");
|
|
8
|
+
//#endregion
|
|
9
|
+
export { o as Steps, f as StepsContent, u as StepsIndicator, c as StepsItem, s as StepsList, d as StepsSeparator, l as StepsTrigger };
|
|
10
|
+
|
|
11
|
+
//# sourceMappingURL=Steps.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Steps.js","names":[],"sources":["../../../src/components/steps/Steps.tsx"],"sourcesContent":["import { Steps as ArkSteps } from '@ark-ui/react'\nimport { ComponentProps } from 'react'\nimport { styled } from '@stokelp/styled-system/jsx'\nimport { steps } from '@stokelp/styled-system/recipes'\nimport { createStyleContext } from '~/utils/slots.tsx'\n\nconst { withProvider, withContext } = createStyleContext(steps)\n\nexport const Steps = withProvider(styled(ArkSteps.Root), 'root')\nexport const StepsList = withContext(styled(ArkSteps.List), 'list')\nexport const StepsItem = withContext(styled(ArkSteps.Item), 'item')\nexport const StepsTrigger = withContext(styled(ArkSteps.Trigger), 'trigger')\nexport const StepsIndicator = withContext(styled(ArkSteps.Indicator), 'indicator')\nexport const StepsSeparator = withContext(styled(ArkSteps.Separator), 'separator')\nexport const StepsContent = withContext(styled(ArkSteps.Content), 'content')\n\nexport interface StepsProps extends ComponentProps<typeof Steps> {}\n\nexport interface StepsListProps extends ComponentProps<typeof StepsList> {}\n\nexport interface StepsItemProps extends ComponentProps<typeof StepsItem> {}\n\nexport interface StepsTriggerProps extends ComponentProps<typeof StepsTrigger> {}\n\nexport interface StepsIndicatorProps extends ComponentProps<typeof StepsIndicator> {}\n\nexport interface StepsSeparatorProps extends ComponentProps<typeof StepsSeparator> {}\n\nexport interface StepsContentProps extends ComponentProps<typeof StepsContent> {}\n"],"mappings":";;;;;;AAMA,IAAM,EAAE,iBAAc,mBAAgB,EAAmB,CAAK,GAEjD,IAAQ,EAAa,EAAO,EAAS,IAAI,GAAG,MAAM,GAClD,IAAY,EAAY,EAAO,EAAS,IAAI,GAAG,MAAM,GACrD,IAAY,EAAY,EAAO,EAAS,IAAI,GAAG,MAAM,GACrD,IAAe,EAAY,EAAO,EAAS,OAAO,GAAG,SAAS,GAC9D,IAAiB,EAAY,EAAO,EAAS,SAAS,GAAG,WAAW,GACpE,IAAiB,EAAY,EAAO,EAAS,SAAS,GAAG,WAAW,GACpE,IAAe,EAAY,EAAO,EAAS,OAAO,GAAG,SAAS"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './Steps';
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use client";const e=require("../text/Text.cjs"),t=require("../icon/Icon.cjs"),n=require("../../node_modules/.pnpm/@heroicons_react@2.2.0_react@19.2.6/node_modules/@heroicons/react/24/outline/esm/CheckCircleIcon.cjs"),r=require("../../node_modules/.pnpm/@heroicons_react@2.2.0_react@19.2.6/node_modules/@heroicons/react/24/outline/esm/XCircleIcon.cjs");let i=require("@stokelp/styled-system/jsx"),a=require("react/jsx-runtime");var o=5,s={title:`Note fournisseur`,insufficientData:`Non noté`,componentsTitle:`Détail de la note`,completionTitle:`Complétion du compte`,notAvailable:`—`,units:{minutes:`min`,hours:`h`,days:`j`},components:{responseRate:`Taux de réponse`,responseDelay:`Délai de réponse`,completion:`Complétion du compte`},completion:{profile:`Profil (photo et description)`,
|
|
1
|
+
"use client";const e=require("../text/Text.cjs"),t=require("../icon/Icon.cjs"),n=require("../../node_modules/.pnpm/@heroicons_react@2.2.0_react@19.2.6/node_modules/@heroicons/react/24/outline/esm/CheckCircleIcon.cjs"),r=require("../../node_modules/.pnpm/@heroicons_react@2.2.0_react@19.2.6/node_modules/@heroicons/react/24/outline/esm/XCircleIcon.cjs");let i=require("@stokelp/styled-system/jsx"),a=require("react/jsx-runtime");var o=5,s={title:`Note fournisseur`,insufficientData:`Non noté`,componentsTitle:`Détail de la note`,completionTitle:`Complétion du compte`,notAvailable:`—`,units:{minutes:`min`,hours:`h`,days:`j`},components:{responseRate:`Taux de réponse`,responseDelay:`Délai de réponse`,completion:`Complétion du compte`},completion:{profile:`Profil (photo et description)`,location:`Localisation`,contacts:`Contact`,legalBanking:`Coordonnées légales et bancaires`,sector:`Secteur d'activité`,certificate:`Certificat`}},c=[`profile`,`location`,`contacts`,`legalBanking`,`sector`,`certificate`];function l(e){return e.toFixed(1).replace(`.`,`,`)}function u(e,t){if(e<60)return`${Math.round(e)} ${t.minutes}`;let n=e/60;return n<48?`${Math.round(n)} ${t.hours}`:`${(n/24).toFixed(1).replace(`.`,`,`)} ${t.days}`}function d(e){let t=e/5;return t>=.7?`#3B6D11`:t>=.4?`#854F0B`:`#A32D2D`}function f(e){return e>=70?`#639922`:e>=40?`#BA7517`:`#E24B4A`}var p=({rating:o,responseRate:p,labels:m})=>{let h={...s,...m,units:{...s.units,...m?.units},components:{...s.components,...m?.components},completion:{...s.completion,...m?.completion}},g=p!=null,_=o.responseDelayMinutes!=null,v=o.responseDelayScore==null?null:Math.round(o.responseDelayScore*100),y=Math.round(o.completionScore*100),b=[{key:`responseRate`,value:g?`${Math.round(p)} %`:h.notAvailable,barPercent:g?Math.round(p):null,color:g?f(Math.round(p)):void 0},{key:`responseDelay`,value:_?u(o.responseDelayMinutes,h.units):h.notAvailable,barPercent:v,color:v==null?void 0:f(v)},{key:`completion`,value:`${y} %`,barPercent:y,color:f(y)}];return(0,a.jsxs)(i.Box,{bg:`white`,borderRadius:`radius-8`,p:`space-16`,minW:`240px`,maxW:`260px`,css:{"& *":{fontFamily:`inherit`}},children:[(0,a.jsxs)(i.HStack,{justify:`space-between`,alignItems:`baseline`,mb:`space-8`,children:[(0,a.jsx)(e.Text,{as:`span`,fontSize:`body.md`,fontWeight:`bold`,children:h.title}),o.insufficientData||o.overall==null?(0,a.jsx)(e.Text,{as:`span`,fontSize:`body.sm`,fontWeight:`medium`,color:`grey.400`,children:h.insufficientData}):(0,a.jsxs)(e.Text,{as:`span`,fontSize:`body.lg`,fontWeight:`medium`,style:{color:d(o.overall)},children:[l(o.overall),` / `,5,` ★`]})]}),(0,a.jsx)(i.Box,{h:`1px`,bg:`grey.100`,mb:`space-8`}),(0,a.jsxs)(i.VStack,{alignItems:`stretch`,gap:`space-8`,mb:`space-8`,children:[(0,a.jsx)(e.Text,{as:`span`,fontSize:`body.sm`,fontWeight:`bold`,color:`grey.400`,children:h.componentsTitle}),b.map(t=>(0,a.jsxs)(i.VStack,{alignItems:`stretch`,gap:`space-2`,children:[(0,a.jsxs)(i.HStack,{justify:`space-between`,alignItems:`baseline`,gap:`space-8`,children:[(0,a.jsx)(e.Text,{as:`span`,fontSize:`body.sm`,color:`grey.500`,children:h.components[t.key]}),(0,a.jsx)(e.Text,{as:`span`,fontSize:`body.sm`,fontWeight:`medium`,whiteSpace:`nowrap`,style:{color:t.color},color:t.color?void 0:`grey.300`,children:t.value})]}),(0,a.jsx)(i.Box,{h:`3px`,bg:`grey.100`,borderRadius:`full`,overflow:`hidden`,children:(0,a.jsx)(i.Box,{h:`100%`,borderRadius:`full`,style:{width:t.barPercent==null?`0%`:`${t.barPercent}%`,background:t.color??`transparent`}})})]},t.key))]}),(0,a.jsx)(i.Box,{h:`1px`,bg:`grey.100`,mb:`space-8`}),(0,a.jsxs)(i.VStack,{alignItems:`stretch`,gap:`space-4`,children:[(0,a.jsx)(e.Text,{as:`span`,fontSize:`body.sm`,fontWeight:`bold`,color:`grey.400`,children:h.completionTitle}),c.map(s=>{let c=o.completion[s];return(0,a.jsxs)(i.HStack,{alignItems:`center`,gap:`space-8`,children:[(0,a.jsx)(t.Icon,{size:`sm`,color:c?`success.500`:`grey.300`,flexShrink:`0`,children:c?(0,a.jsx)(n.default,{}):(0,a.jsx)(r.default,{})}),(0,a.jsx)(e.Text,{as:`span`,fontSize:`body.sm`,color:c?`grey.500`:`grey.400`,children:h.completion[s]})]},s)})]}),h.footer&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(i.Box,{h:`1px`,bg:`grey.100`,mt:`space-8`,mb:`space-8`}),(0,a.jsx)(e.Text,{as:`span`,fontSize:`9px`,color:`grey.300`,style:{lineHeight:1},children:h.footer})]})]})};exports.DEFAULT_SUPPLIER_RATING_LABELS=s,exports.SUPPLIER_RATING_MAX=o,exports.SupplierRatingBreakdown=p,exports.formatOverall=l,exports.formatResponseDelay=u,exports.getHeadlineColor=d;
|
|
2
2
|
//# sourceMappingURL=SupplierRatingBreakdown.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SupplierRatingBreakdown.cjs","names":[],"sources":["../../../src/components/supplier-rating-badge/SupplierRatingBreakdown.tsx"],"sourcesContent":["import { CheckCircleIcon, XCircleIcon } from '@heroicons/react/24/outline'\nimport { Box, HStack, VStack } from '@stokelp/styled-system/jsx'\n\nimport { Icon, Text } from '~/components'\n\nexport const SUPPLIER_RATING_MAX = 5\n\nexport type SupplierRatingComponentKey = 'responseRate' | 'responseDelay' | 'completion'\n\nexport type SupplierRatingCompletionKey =\n | 'profile'\n | 'locationContacts'\n | 'legalBanking'\n | 'sector'\n | 'certificate'\n | 'productInterest'\n\nexport type SupplierRatingCompletion = Record<SupplierRatingCompletionKey, boolean>\n\nexport type SupplierRating = {\n /** Overall note out of 5. Absent when insufficientData is true. */\n overall?: number\n /** Response-rate sub-score, 0..1 (note calc only). Absent when insufficientData is true. */\n responseRateScore?: number\n /** Response-delay sub-score, 0..1 (note calc + colours the delay row). Absent when insufficientData is true. */\n responseDelayScore?: number\n /** Average response delay in MINUTES, for display. Absent when insufficientData is true. */\n responseDelayMinutes?: number\n /** Account-completion sub-score, 0..1. Always present. */\n completionScore: number\n /** True when the supplier has too few interactions for a reliable note. */\n insufficientData: boolean\n /** Completion checklist shown in the breakdown. */\n completion: SupplierRatingCompletion\n}\n\nexport type SupplierRatingLabels = {\n title: string\n /** Neutral state shown instead of a note when data is insufficient. */\n insufficientData: string\n /** Section heading above the sub-scores. */\n componentsTitle: string\n /** Section heading above the completion checklist. */\n completionTitle: string\n /** Value shown when a component has no data yet (e.g. \"—\"). */\n notAvailable: string\n /** Unit suffixes for the average response-delay value. */\n units: { minutes: string; hours: string; days: string }\n components: Record<SupplierRatingComponentKey, string>\n completion: Record<SupplierRatingCompletionKey, string>\n footer?: string\n}\n\nexport const DEFAULT_SUPPLIER_RATING_LABELS: SupplierRatingLabels = {\n title: 'Note fournisseur',\n insufficientData: 'Non noté',\n componentsTitle: 'Détail de la note',\n completionTitle: 'Complétion du compte',\n notAvailable: '—',\n units: { minutes: 'min', hours: 'h', days: 'j' },\n components: {\n responseRate: 'Taux de réponse',\n responseDelay: 'Délai de réponse',\n completion: 'Complétion du compte',\n },\n completion: {\n profile: 'Profil (photo et description)',\n locationContacts: 'Localisation et contact',\n legalBanking: 'Coordonnées légales et bancaires',\n sector: \"Secteur d'activité\",\n certificate: 'Certificat',\n productInterest: 'Intérêt produit',\n },\n}\n\nconst COMPLETION_ORDER: SupplierRatingCompletionKey[] = [\n 'profile',\n 'locationContacts',\n 'legalBanking',\n 'sector',\n 'certificate',\n 'productInterest',\n]\n\nexport function formatOverall(overall: number): string {\n return overall.toFixed(1).replace('.', ',')\n}\n\n/** Average response delay: minutes → \"45 min\" / \"18 h\" / \"2,5 j\". */\nexport function formatResponseDelay(minutes: number, units: SupplierRatingLabels['units']): string {\n if (minutes < 60) return `${Math.round(minutes)} ${units.minutes}`\n const hours = minutes / 60\n if (hours < 48) return `${Math.round(hours)} ${units.hours}`\n const days = hours / 24\n return `${days.toFixed(1).replace('.', ',')} ${units.days}`\n}\n\nexport function getHeadlineColor(overall: number): string {\n const ratio = overall / SUPPLIER_RATING_MAX\n if (ratio >= 0.7) return '#3B6D11'\n if (ratio >= 0.4) return '#854F0B'\n return '#A32D2D'\n}\n\nfunction getBarColor(ratioPercent: number): string {\n if (ratioPercent >= 70) return '#639922'\n if (ratioPercent >= 40) return '#BA7517'\n return '#E24B4A'\n}\n\ntype ComponentRow = {\n key: SupplierRatingComponentKey\n value: string\n /** 0..100 bar fill, or null when there is no data. */\n barPercent: number | null\n /** Bar/value colour, or undefined for the neutral (no-data) state. */\n color?: string\n}\n\ntype SupplierRatingBreakdownProps = {\n rating: SupplierRating\n /** Original response rate (0..100), displayed as the \"Taux de réponse\" value. */\n responseRate?: number\n labels?: Partial<SupplierRatingLabels>\n}\n\nexport const SupplierRatingBreakdown = ({ rating, responseRate, labels: labelsProp }: SupplierRatingBreakdownProps) => {\n const labels: SupplierRatingLabels = {\n ...DEFAULT_SUPPLIER_RATING_LABELS,\n ...labelsProp,\n units: { ...DEFAULT_SUPPLIER_RATING_LABELS.units, ...labelsProp?.units },\n components: { ...DEFAULT_SUPPLIER_RATING_LABELS.components, ...labelsProp?.components },\n completion: { ...DEFAULT_SUPPLIER_RATING_LABELS.completion, ...labelsProp?.completion },\n }\n\n const hasResponseRate = responseRate != null\n const hasDelay = rating.responseDelayMinutes != null\n const delayPercent = rating.responseDelayScore != null ? Math.round(rating.responseDelayScore * 100) : null\n const completionPercent = Math.round(rating.completionScore * 100)\n\n const rows: ComponentRow[] = [\n {\n key: 'responseRate',\n value: hasResponseRate ? `${Math.round(responseRate)} %` : labels.notAvailable,\n barPercent: hasResponseRate ? Math.round(responseRate) : null,\n color: hasResponseRate ? getBarColor(Math.round(responseRate)) : undefined,\n },\n {\n key: 'responseDelay',\n value: hasDelay ? formatResponseDelay(rating.responseDelayMinutes as number, labels.units) : labels.notAvailable,\n barPercent: delayPercent,\n color: delayPercent != null ? getBarColor(delayPercent) : undefined,\n },\n {\n key: 'completion',\n value: `${completionPercent} %`,\n barPercent: completionPercent,\n color: getBarColor(completionPercent),\n },\n ]\n\n return (\n <Box\n bg=\"white\"\n borderRadius=\"radius-8\"\n p=\"space-16\"\n minW=\"240px\"\n maxW=\"260px\"\n css={{ '& *': { fontFamily: 'inherit' } }}\n >\n <HStack justify=\"space-between\" alignItems=\"baseline\" mb=\"space-8\">\n <Text as=\"span\" fontSize=\"body.md\" fontWeight=\"bold\">\n {labels.title}\n </Text>\n {rating.insufficientData || rating.overall == null ? (\n <Text as=\"span\" fontSize=\"body.sm\" fontWeight=\"medium\" color=\"grey.400\">\n {labels.insufficientData}\n </Text>\n ) : (\n <Text as=\"span\" fontSize=\"body.lg\" fontWeight=\"medium\" style={{ color: getHeadlineColor(rating.overall) }}>\n {formatOverall(rating.overall)} / {SUPPLIER_RATING_MAX} ★\n </Text>\n )}\n </HStack>\n\n <Box h=\"1px\" bg=\"grey.100\" mb=\"space-8\" />\n\n <VStack alignItems=\"stretch\" gap=\"space-8\" mb=\"space-8\">\n <Text as=\"span\" fontSize=\"body.sm\" fontWeight=\"bold\" color=\"grey.400\">\n {labels.componentsTitle}\n </Text>\n {rows.map(row => (\n <VStack key={row.key} alignItems=\"stretch\" gap=\"space-2\">\n <HStack justify=\"space-between\" alignItems=\"baseline\" gap=\"space-8\">\n <Text as=\"span\" fontSize=\"body.sm\" color=\"grey.500\">\n {labels.components[row.key]}\n </Text>\n <Text\n as=\"span\"\n fontSize=\"body.sm\"\n fontWeight=\"medium\"\n whiteSpace=\"nowrap\"\n style={{ color: row.color }}\n color={row.color ? undefined : 'grey.300'}\n >\n {row.value}\n </Text>\n </HStack>\n <Box h=\"3px\" bg=\"grey.100\" borderRadius=\"full\" overflow=\"hidden\">\n <Box\n h=\"100%\"\n borderRadius=\"full\"\n style={{\n width: row.barPercent != null ? `${row.barPercent}%` : '0%',\n background: row.color ?? 'transparent',\n }}\n />\n </Box>\n </VStack>\n ))}\n </VStack>\n\n <Box h=\"1px\" bg=\"grey.100\" mb=\"space-8\" />\n\n <VStack alignItems=\"stretch\" gap=\"space-4\">\n <Text as=\"span\" fontSize=\"body.sm\" fontWeight=\"bold\" color=\"grey.400\">\n {labels.completionTitle}\n </Text>\n {COMPLETION_ORDER.map(key => {\n const done = rating.completion[key]\n return (\n <HStack key={key} alignItems=\"center\" gap=\"space-8\">\n <Icon size=\"sm\" color={done ? 'success.500' : 'grey.300'} flexShrink=\"0\">\n {done ? <CheckCircleIcon /> : <XCircleIcon />}\n </Icon>\n <Text as=\"span\" fontSize=\"body.sm\" color={done ? 'grey.500' : 'grey.400'}>\n {labels.completion[key]}\n </Text>\n </HStack>\n )\n })}\n </VStack>\n\n {labels.footer && (\n <>\n <Box h=\"1px\" bg=\"grey.100\" mt=\"space-8\" mb=\"space-8\" />\n <Text as=\"span\" fontSize=\"9px\" color=\"grey.300\" style={{ lineHeight: 1 }}>\n {labels.footer}\n </Text>\n </>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AC,EAAA,KAAD,CAAM,GAAG,OAAO,SAAS,UAAU,WAAW,OAAO,MAAM,oBACxD,EAAO,eACJ,CAAA,EACL,EAAiB,IAAI,GAAO,CAC3B,IAAM,EAAO,EAAO,WAAW,GAC/B,OACE,EAAA,EAAA,MAAC,EAAA,OAAD,CAAkB,WAAW,SAAS,IAAI,mBAA1C,EACE,EAAA,EAAA,KAAC,EAAA,KAAD,CAAM,KAAK,KAAK,MAAO,EAAO,cAAgB,WAAY,WAAW,aAClE,GAAO,EAAA,EAAA,KAAC,EAAA,QAAD,CAAkB,CAAA,GAAI,EAAA,EAAA,KAAC,EAAA,QAAD,CAAc,CAAA,CACxC,CAAA,GACN,EAAA,EAAA,KAAC,EAAA,KAAD,CAAM,GAAG,OAAO,SAAS,UAAU,MAAO,EAAO,WAAa,oBAC3D,EAAO,WAAW,EACf,CAAA,CACA,GAPK,CAOL,CAEZ,CAAC,CACK,IAEP,EAAO,SACN,EAAA,EAAA,MAAA,EAAA,SAAA,CAAA,SAAA,EACE,EAAA,EAAA,KAAC,EAAA,IAAD,CAAK,EAAE,MAAM,GAAG,WAAW,GAAG,UAAU,GAAG,SAAW,CAAA,GACtD,EAAA,EAAA,KAAC,EAAA,KAAD,CAAM,GAAG,OAAO,SAAS,MAAM,MAAM,WAAW,MAAO,CAAE,WAAY,CAAE,WACpE,EAAO,MACJ,CAAA,CACN,CAAA,CAAA,CAED,GAET"}
|
|
1
|
+
{"version":3,"file":"SupplierRatingBreakdown.cjs","names":[],"sources":["../../../src/components/supplier-rating-badge/SupplierRatingBreakdown.tsx"],"sourcesContent":["import { CheckCircleIcon, XCircleIcon } from '@heroicons/react/24/outline'\nimport { Box, HStack, VStack } from '@stokelp/styled-system/jsx'\n\nimport { Icon, Text } from '~/components'\n\nexport const SUPPLIER_RATING_MAX = 5\n\nexport type SupplierRatingComponentKey = 'responseRate' | 'responseDelay' | 'completion'\n\nexport type SupplierRatingCompletionKey =\n | 'profile'\n | 'location'\n | 'contacts'\n | 'legalBanking'\n | 'sector'\n | 'certificate'\n\nexport type SupplierRatingCompletion = Record<SupplierRatingCompletionKey, boolean>\n\nexport type SupplierRating = {\n /** Overall note out of 5. Absent when insufficientData is true. */\n overall?: number\n /** Response-rate sub-score, 0..1 (note calc only). Absent when insufficientData is true. */\n responseRateScore?: number\n /** Response-delay sub-score, 0..1 (note calc + colours the delay row). Absent when insufficientData is true. */\n responseDelayScore?: number\n /** Average response delay in MINUTES, for display. Absent when insufficientData is true. */\n responseDelayMinutes?: number\n /** Account-completion sub-score, 0..1. Always present. */\n completionScore: number\n /** True when the supplier has too few interactions for a reliable note. */\n insufficientData: boolean\n /** Completion checklist shown in the breakdown. */\n completion: SupplierRatingCompletion\n}\n\nexport type SupplierRatingLabels = {\n title: string\n /** Neutral state shown instead of a note when data is insufficient. */\n insufficientData: string\n /** Section heading above the sub-scores. */\n componentsTitle: string\n /** Section heading above the completion checklist. */\n completionTitle: string\n /** Value shown when a component has no data yet (e.g. \"—\"). */\n notAvailable: string\n /** Unit suffixes for the average response-delay value. */\n units: { minutes: string; hours: string; days: string }\n components: Record<SupplierRatingComponentKey, string>\n completion: Record<SupplierRatingCompletionKey, string>\n footer?: string\n}\n\nexport const DEFAULT_SUPPLIER_RATING_LABELS: SupplierRatingLabels = {\n title: 'Note fournisseur',\n insufficientData: 'Non noté',\n componentsTitle: 'Détail de la note',\n completionTitle: 'Complétion du compte',\n notAvailable: '—',\n units: { minutes: 'min', hours: 'h', days: 'j' },\n components: {\n responseRate: 'Taux de réponse',\n responseDelay: 'Délai de réponse',\n completion: 'Complétion du compte',\n },\n completion: {\n profile: 'Profil (photo et description)',\n location: 'Localisation',\n contacts: 'Contact',\n legalBanking: 'Coordonnées légales et bancaires',\n sector: \"Secteur d'activité\",\n certificate: 'Certificat',\n },\n}\n\nconst COMPLETION_ORDER: SupplierRatingCompletionKey[] = [\n 'profile',\n 'location',\n 'contacts',\n 'legalBanking',\n 'sector',\n 'certificate',\n]\n\nexport function formatOverall(overall: number): string {\n return overall.toFixed(1).replace('.', ',')\n}\n\n/** Average response delay: minutes → \"45 min\" / \"18 h\" / \"2,5 j\". */\nexport function formatResponseDelay(minutes: number, units: SupplierRatingLabels['units']): string {\n if (minutes < 60) return `${Math.round(minutes)} ${units.minutes}`\n const hours = minutes / 60\n if (hours < 48) return `${Math.round(hours)} ${units.hours}`\n const days = hours / 24\n return `${days.toFixed(1).replace('.', ',')} ${units.days}`\n}\n\nexport function getHeadlineColor(overall: number): string {\n const ratio = overall / SUPPLIER_RATING_MAX\n if (ratio >= 0.7) return '#3B6D11'\n if (ratio >= 0.4) return '#854F0B'\n return '#A32D2D'\n}\n\nfunction getBarColor(ratioPercent: number): string {\n if (ratioPercent >= 70) return '#639922'\n if (ratioPercent >= 40) return '#BA7517'\n return '#E24B4A'\n}\n\ntype ComponentRow = {\n key: SupplierRatingComponentKey\n value: string\n /** 0..100 bar fill, or null when there is no data. */\n barPercent: number | null\n /** Bar/value colour, or undefined for the neutral (no-data) state. */\n color?: string\n}\n\ntype SupplierRatingBreakdownProps = {\n rating: SupplierRating\n /** Original response rate (0..100), displayed as the \"Taux de réponse\" value. */\n responseRate?: number\n labels?: Partial<SupplierRatingLabels>\n}\n\nexport const SupplierRatingBreakdown = ({ rating, responseRate, labels: labelsProp }: SupplierRatingBreakdownProps) => {\n const labels: SupplierRatingLabels = {\n ...DEFAULT_SUPPLIER_RATING_LABELS,\n ...labelsProp,\n units: { ...DEFAULT_SUPPLIER_RATING_LABELS.units, ...labelsProp?.units },\n components: { ...DEFAULT_SUPPLIER_RATING_LABELS.components, ...labelsProp?.components },\n completion: { ...DEFAULT_SUPPLIER_RATING_LABELS.completion, ...labelsProp?.completion },\n }\n\n const hasResponseRate = responseRate != null\n const hasDelay = rating.responseDelayMinutes != null\n const delayPercent = rating.responseDelayScore != null ? Math.round(rating.responseDelayScore * 100) : null\n const completionPercent = Math.round(rating.completionScore * 100)\n\n const rows: ComponentRow[] = [\n {\n key: 'responseRate',\n value: hasResponseRate ? `${Math.round(responseRate)} %` : labels.notAvailable,\n barPercent: hasResponseRate ? Math.round(responseRate) : null,\n color: hasResponseRate ? getBarColor(Math.round(responseRate)) : undefined,\n },\n {\n key: 'responseDelay',\n value: hasDelay ? formatResponseDelay(rating.responseDelayMinutes as number, labels.units) : labels.notAvailable,\n barPercent: delayPercent,\n color: delayPercent != null ? getBarColor(delayPercent) : undefined,\n },\n {\n key: 'completion',\n value: `${completionPercent} %`,\n barPercent: completionPercent,\n color: getBarColor(completionPercent),\n },\n ]\n\n return (\n <Box\n bg=\"white\"\n borderRadius=\"radius-8\"\n p=\"space-16\"\n minW=\"240px\"\n maxW=\"260px\"\n css={{ '& *': { fontFamily: 'inherit' } }}\n >\n <HStack justify=\"space-between\" alignItems=\"baseline\" mb=\"space-8\">\n <Text as=\"span\" fontSize=\"body.md\" fontWeight=\"bold\">\n {labels.title}\n </Text>\n {rating.insufficientData || rating.overall == null ? (\n <Text as=\"span\" fontSize=\"body.sm\" fontWeight=\"medium\" color=\"grey.400\">\n {labels.insufficientData}\n </Text>\n ) : (\n <Text as=\"span\" fontSize=\"body.lg\" fontWeight=\"medium\" style={{ color: getHeadlineColor(rating.overall) }}>\n {formatOverall(rating.overall)} / {SUPPLIER_RATING_MAX} ★\n </Text>\n )}\n </HStack>\n\n <Box h=\"1px\" bg=\"grey.100\" mb=\"space-8\" />\n\n <VStack alignItems=\"stretch\" gap=\"space-8\" mb=\"space-8\">\n <Text as=\"span\" fontSize=\"body.sm\" fontWeight=\"bold\" color=\"grey.400\">\n {labels.componentsTitle}\n </Text>\n {rows.map(row => (\n <VStack key={row.key} alignItems=\"stretch\" gap=\"space-2\">\n <HStack justify=\"space-between\" alignItems=\"baseline\" gap=\"space-8\">\n <Text as=\"span\" fontSize=\"body.sm\" color=\"grey.500\">\n {labels.components[row.key]}\n </Text>\n <Text\n as=\"span\"\n fontSize=\"body.sm\"\n fontWeight=\"medium\"\n whiteSpace=\"nowrap\"\n style={{ color: row.color }}\n color={row.color ? undefined : 'grey.300'}\n >\n {row.value}\n </Text>\n </HStack>\n <Box h=\"3px\" bg=\"grey.100\" borderRadius=\"full\" overflow=\"hidden\">\n <Box\n h=\"100%\"\n borderRadius=\"full\"\n style={{\n width: row.barPercent != null ? `${row.barPercent}%` : '0%',\n background: row.color ?? 'transparent',\n }}\n />\n </Box>\n </VStack>\n ))}\n </VStack>\n\n <Box h=\"1px\" bg=\"grey.100\" mb=\"space-8\" />\n\n <VStack alignItems=\"stretch\" gap=\"space-4\">\n <Text as=\"span\" fontSize=\"body.sm\" fontWeight=\"bold\" color=\"grey.400\">\n {labels.completionTitle}\n </Text>\n {COMPLETION_ORDER.map(key => {\n const done = rating.completion[key]\n return (\n <HStack key={key} alignItems=\"center\" gap=\"space-8\">\n <Icon size=\"sm\" color={done ? 'success.500' : 'grey.300'} flexShrink=\"0\">\n {done ? <CheckCircleIcon /> : <XCircleIcon />}\n </Icon>\n <Text as=\"span\" fontSize=\"body.sm\" color={done ? 'grey.500' : 'grey.400'}>\n {labels.completion[key]}\n </Text>\n </HStack>\n )\n })}\n </VStack>\n\n {labels.footer && (\n <>\n <Box h=\"1px\" bg=\"grey.100\" mt=\"space-8\" mb=\"space-8\" />\n <Text as=\"span\" fontSize=\"9px\" color=\"grey.300\" style={{ lineHeight: 1 }}>\n {labels.footer}\n </Text>\n </>\n )}\n </Box>\n )\n}\n"],"mappings":"4aAKA,IAAa,EAAsB,EAgDtB,EAAuD,CAClE,MAAO,mBACP,iBAAkB,WAClB,gBAAiB,oBACjB,gBAAiB,uBACjB,aAAc,IACd,MAAO,CAAE,QAAS,MAAO,MAAO,IAAK,KAAM,GAAI,EAC/C,WAAY,CACV,aAAc,kBACd,cAAe,mBACf,WAAY,sBACd,EACA,WAAY,CACV,QAAS,gCACT,SAAU,eACV,SAAU,UACV,aAAc,mCACd,OAAQ,qBACR,YAAa,YACf,CACF,EAEM,EAAkD,CACtD,UACA,WACA,WACA,eACA,SACA,aACF,EAEA,SAAgB,EAAc,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CAAA,GACN,EAAA,EAAA,KAAC,EAAA,KAAD,CAAM,GAAG,OAAO,SAAS,UAAU,MAAO,EAAO,WAAa,oBAC3D,EAAO,WAAW,EACf,CAAA,CACA,GAPK,CAOL,CAEZ,CAAC,CACK,IAEP,EAAO,SACN,EAAA,EAAA,MAAA,EAAA,SAAA,CAAA,SAAA,EACE,EAAA,EAAA,KAAC,EAAA,IAAD,CAAK,EAAE,MAAM,GAAG,WAAW,GAAG,UAAU,GAAG,SAAW,CAAA,GACtD,EAAA,EAAA,KAAC,EAAA,KAAD,CAAM,GAAG,OAAO,SAAS,MAAM,MAAM,WAAW,MAAO,CAAE,WAAY,CAAE,WACpE,EAAO,MACJ,CAAA,CACN,CAAA,CAAA,CAED,GAET"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export declare const SUPPLIER_RATING_MAX = 5;
|
|
2
2
|
export type SupplierRatingComponentKey = 'responseRate' | 'responseDelay' | 'completion';
|
|
3
|
-
export type SupplierRatingCompletionKey = 'profile' | '
|
|
3
|
+
export type SupplierRatingCompletionKey = 'profile' | 'location' | 'contacts' | 'legalBanking' | 'sector' | 'certificate';
|
|
4
4
|
export type SupplierRatingCompletion = Record<SupplierRatingCompletionKey, boolean>;
|
|
5
5
|
export type SupplierRating = {
|
|
6
6
|
/** Overall note out of 5. Absent when insufficientData is true. */
|
|
@@ -24,19 +24,19 @@ var u = 5, d = {
|
|
|
24
24
|
},
|
|
25
25
|
completion: {
|
|
26
26
|
profile: "Profil (photo et description)",
|
|
27
|
-
|
|
27
|
+
location: "Localisation",
|
|
28
|
+
contacts: "Contact",
|
|
28
29
|
legalBanking: "Coordonnées légales et bancaires",
|
|
29
30
|
sector: "Secteur d'activité",
|
|
30
|
-
certificate: "Certificat"
|
|
31
|
-
productInterest: "Intérêt produit"
|
|
31
|
+
certificate: "Certificat"
|
|
32
32
|
}
|
|
33
33
|
}, f = [
|
|
34
34
|
"profile",
|
|
35
|
-
"
|
|
35
|
+
"location",
|
|
36
|
+
"contacts",
|
|
36
37
|
"legalBanking",
|
|
37
38
|
"sector",
|
|
38
|
-
"certificate"
|
|
39
|
-
"productInterest"
|
|
39
|
+
"certificate"
|
|
40
40
|
];
|
|
41
41
|
function p(e) {
|
|
42
42
|
return e.toFixed(1).replace(".", ",");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SupplierRatingBreakdown.js","names":[],"sources":["../../../src/components/supplier-rating-badge/SupplierRatingBreakdown.tsx"],"sourcesContent":["import { CheckCircleIcon, XCircleIcon } from '@heroicons/react/24/outline'\nimport { Box, HStack, VStack } from '@stokelp/styled-system/jsx'\n\nimport { Icon, Text } from '~/components'\n\nexport const SUPPLIER_RATING_MAX = 5\n\nexport type SupplierRatingComponentKey = 'responseRate' | 'responseDelay' | 'completion'\n\nexport type SupplierRatingCompletionKey =\n | 'profile'\n | 'locationContacts'\n | 'legalBanking'\n | 'sector'\n | 'certificate'\n | 'productInterest'\n\nexport type SupplierRatingCompletion = Record<SupplierRatingCompletionKey, boolean>\n\nexport type SupplierRating = {\n /** Overall note out of 5. Absent when insufficientData is true. */\n overall?: number\n /** Response-rate sub-score, 0..1 (note calc only). Absent when insufficientData is true. */\n responseRateScore?: number\n /** Response-delay sub-score, 0..1 (note calc + colours the delay row). Absent when insufficientData is true. */\n responseDelayScore?: number\n /** Average response delay in MINUTES, for display. Absent when insufficientData is true. */\n responseDelayMinutes?: number\n /** Account-completion sub-score, 0..1. Always present. */\n completionScore: number\n /** True when the supplier has too few interactions for a reliable note. */\n insufficientData: boolean\n /** Completion checklist shown in the breakdown. */\n completion: SupplierRatingCompletion\n}\n\nexport type SupplierRatingLabels = {\n title: string\n /** Neutral state shown instead of a note when data is insufficient. */\n insufficientData: string\n /** Section heading above the sub-scores. */\n componentsTitle: string\n /** Section heading above the completion checklist. */\n completionTitle: string\n /** Value shown when a component has no data yet (e.g. \"—\"). */\n notAvailable: string\n /** Unit suffixes for the average response-delay value. */\n units: { minutes: string; hours: string; days: string }\n components: Record<SupplierRatingComponentKey, string>\n completion: Record<SupplierRatingCompletionKey, string>\n footer?: string\n}\n\nexport const DEFAULT_SUPPLIER_RATING_LABELS: SupplierRatingLabels = {\n title: 'Note fournisseur',\n insufficientData: 'Non noté',\n componentsTitle: 'Détail de la note',\n completionTitle: 'Complétion du compte',\n notAvailable: '—',\n units: { minutes: 'min', hours: 'h', days: 'j' },\n components: {\n responseRate: 'Taux de réponse',\n responseDelay: 'Délai de réponse',\n completion: 'Complétion du compte',\n },\n completion: {\n profile: 'Profil (photo et description)',\n locationContacts: 'Localisation et contact',\n legalBanking: 'Coordonnées légales et bancaires',\n sector: \"Secteur d'activité\",\n certificate: 'Certificat',\n productInterest: 'Intérêt produit',\n },\n}\n\nconst COMPLETION_ORDER: SupplierRatingCompletionKey[] = [\n 'profile',\n 'locationContacts',\n 'legalBanking',\n 'sector',\n 'certificate',\n 'productInterest',\n]\n\nexport function formatOverall(overall: number): string {\n return overall.toFixed(1).replace('.', ',')\n}\n\n/** Average response delay: minutes → \"45 min\" / \"18 h\" / \"2,5 j\". */\nexport function formatResponseDelay(minutes: number, units: SupplierRatingLabels['units']): string {\n if (minutes < 60) return `${Math.round(minutes)} ${units.minutes}`\n const hours = minutes / 60\n if (hours < 48) return `${Math.round(hours)} ${units.hours}`\n const days = hours / 24\n return `${days.toFixed(1).replace('.', ',')} ${units.days}`\n}\n\nexport function getHeadlineColor(overall: number): string {\n const ratio = overall / SUPPLIER_RATING_MAX\n if (ratio >= 0.7) return '#3B6D11'\n if (ratio >= 0.4) return '#854F0B'\n return '#A32D2D'\n}\n\nfunction getBarColor(ratioPercent: number): string {\n if (ratioPercent >= 70) return '#639922'\n if (ratioPercent >= 40) return '#BA7517'\n return '#E24B4A'\n}\n\ntype ComponentRow = {\n key: SupplierRatingComponentKey\n value: string\n /** 0..100 bar fill, or null when there is no data. */\n barPercent: number | null\n /** Bar/value colour, or undefined for the neutral (no-data) state. */\n color?: string\n}\n\ntype SupplierRatingBreakdownProps = {\n rating: SupplierRating\n /** Original response rate (0..100), displayed as the \"Taux de réponse\" value. */\n responseRate?: number\n labels?: Partial<SupplierRatingLabels>\n}\n\nexport const SupplierRatingBreakdown = ({ rating, responseRate, labels: labelsProp }: SupplierRatingBreakdownProps) => {\n const labels: SupplierRatingLabels = {\n ...DEFAULT_SUPPLIER_RATING_LABELS,\n ...labelsProp,\n units: { ...DEFAULT_SUPPLIER_RATING_LABELS.units, ...labelsProp?.units },\n components: { ...DEFAULT_SUPPLIER_RATING_LABELS.components, ...labelsProp?.components },\n completion: { ...DEFAULT_SUPPLIER_RATING_LABELS.completion, ...labelsProp?.completion },\n }\n\n const hasResponseRate = responseRate != null\n const hasDelay = rating.responseDelayMinutes != null\n const delayPercent = rating.responseDelayScore != null ? Math.round(rating.responseDelayScore * 100) : null\n const completionPercent = Math.round(rating.completionScore * 100)\n\n const rows: ComponentRow[] = [\n {\n key: 'responseRate',\n value: hasResponseRate ? `${Math.round(responseRate)} %` : labels.notAvailable,\n barPercent: hasResponseRate ? Math.round(responseRate) : null,\n color: hasResponseRate ? getBarColor(Math.round(responseRate)) : undefined,\n },\n {\n key: 'responseDelay',\n value: hasDelay ? formatResponseDelay(rating.responseDelayMinutes as number, labels.units) : labels.notAvailable,\n barPercent: delayPercent,\n color: delayPercent != null ? getBarColor(delayPercent) : undefined,\n },\n {\n key: 'completion',\n value: `${completionPercent} %`,\n barPercent: completionPercent,\n color: getBarColor(completionPercent),\n },\n ]\n\n return (\n <Box\n bg=\"white\"\n borderRadius=\"radius-8\"\n p=\"space-16\"\n minW=\"240px\"\n maxW=\"260px\"\n css={{ '& *': { fontFamily: 'inherit' } }}\n >\n <HStack justify=\"space-between\" alignItems=\"baseline\" mb=\"space-8\">\n <Text as=\"span\" fontSize=\"body.md\" fontWeight=\"bold\">\n {labels.title}\n </Text>\n {rating.insufficientData || rating.overall == null ? (\n <Text as=\"span\" fontSize=\"body.sm\" fontWeight=\"medium\" color=\"grey.400\">\n {labels.insufficientData}\n </Text>\n ) : (\n <Text as=\"span\" fontSize=\"body.lg\" fontWeight=\"medium\" style={{ color: getHeadlineColor(rating.overall) }}>\n {formatOverall(rating.overall)} / {SUPPLIER_RATING_MAX} ★\n </Text>\n )}\n </HStack>\n\n <Box h=\"1px\" bg=\"grey.100\" mb=\"space-8\" />\n\n <VStack alignItems=\"stretch\" gap=\"space-8\" mb=\"space-8\">\n <Text as=\"span\" fontSize=\"body.sm\" fontWeight=\"bold\" color=\"grey.400\">\n {labels.componentsTitle}\n </Text>\n {rows.map(row => (\n <VStack key={row.key} alignItems=\"stretch\" gap=\"space-2\">\n <HStack justify=\"space-between\" alignItems=\"baseline\" gap=\"space-8\">\n <Text as=\"span\" fontSize=\"body.sm\" color=\"grey.500\">\n {labels.components[row.key]}\n </Text>\n <Text\n as=\"span\"\n fontSize=\"body.sm\"\n fontWeight=\"medium\"\n whiteSpace=\"nowrap\"\n style={{ color: row.color }}\n color={row.color ? undefined : 'grey.300'}\n >\n {row.value}\n </Text>\n </HStack>\n <Box h=\"3px\" bg=\"grey.100\" borderRadius=\"full\" overflow=\"hidden\">\n <Box\n h=\"100%\"\n borderRadius=\"full\"\n style={{\n width: row.barPercent != null ? `${row.barPercent}%` : '0%',\n background: row.color ?? 'transparent',\n }}\n />\n </Box>\n </VStack>\n ))}\n </VStack>\n\n <Box h=\"1px\" bg=\"grey.100\" mb=\"space-8\" />\n\n <VStack alignItems=\"stretch\" gap=\"space-4\">\n <Text as=\"span\" fontSize=\"body.sm\" fontWeight=\"bold\" color=\"grey.400\">\n {labels.completionTitle}\n </Text>\n {COMPLETION_ORDER.map(key => {\n const done = rating.completion[key]\n return (\n <HStack key={key} alignItems=\"center\" gap=\"space-8\">\n <Icon size=\"sm\" color={done ? 'success.500' : 'grey.300'} flexShrink=\"0\">\n {done ? <CheckCircleIcon /> : <XCircleIcon />}\n </Icon>\n <Text as=\"span\" fontSize=\"body.sm\" color={done ? 'grey.500' : 'grey.400'}>\n {labels.completion[key]}\n </Text>\n </HStack>\n )\n })}\n </VStack>\n\n {labels.footer && (\n <>\n <Box h=\"1px\" bg=\"grey.100\" mt=\"space-8\" mb=\"space-8\" />\n <Text as=\"span\" fontSize=\"9px\" color=\"grey.300\" style={{ lineHeight: 1 }}>\n {labels.footer}\n </Text>\n </>\n )}\n </Box>\n )\n}\n"],"mappings":";;;;;;;;AAKA,IAAa,IAAsB,GAgDtB,IAAuD;CAClE,OAAO;CACP,kBAAkB;CAClB,iBAAiB;CACjB,iBAAiB;CACjB,cAAc;CACd,OAAO;EAAE,SAAS;EAAO,OAAO;EAAK,MAAM;CAAI;CAC/C,YAAY;EACV,cAAc;EACd,eAAe;EACf,YAAY;CACd;CACA,YAAY;EACV,SAAS;EACT,kBAAkB;EAClB,cAAc;EACd,QAAQ;EACR,aAAa;EACb,iBAAiB;CACnB;AACF,GAEM,IAAkD;CACtD;CACA;CACA;CACA;CACA;CACA;AACF;AAEA,SAAgB,EAAc,GAAyB;CACrD,OAAO,EAAQ,QAAQ,CAAC,EAAE,QAAQ,KAAK,GAAG;AAC5C;AAGA,SAAgB,EAAoB,GAAiB,GAA8C;CACjG,IAAI,IAAU,IAAI,OAAO,GAAG,KAAK,MAAM,CAAO,EAAE,GAAG,EAAM;CACzD,IAAM,IAAQ,IAAU;CAGxB,OAFI,IAAQ,KAAW,GAAG,KAAK,MAAM,CAAK,EAAE,GAAG,EAAM,UAE9C,IADM,IAAQ,IACN,QAAQ,CAAC,EAAE,QAAQ,KAAK,GAAG,EAAE,GAAG,EAAM;AACvD;AAEA,SAAgB,EAAiB,GAAyB;CACxD,IAAM,IAAQ,IAAA;CAGd,OAFI,KAAS,KAAY,YACrB,KAAS,KAAY,YAClB;AACT;AAEA,SAAS,EAAY,GAA8B;CAGjD,OAFI,KAAgB,KAAW,YAC3B,KAAgB,KAAW,YACxB;AACT;AAkBA,IAAa,KAA2B,EAAE,WAAQ,iBAAc,QAAQ,QAA+C;CACrH,IAAM,IAA+B;EACnC,GAAG;EACH,GAAG;EAC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IAAO,EAAO,WAAW;KAC/B,OACE,kBAAC,GAAD;MAAkB,YAAW;MAAS,KAAI;gBAA1C,CACE,kBAAC,GAAD;OAAM,MAAK;OAAK,OAAO,IAAO,gBAAgB;OAAY,YAAW;iBAC3D,EAAP,IAAQ,IAAsB,GAAvB,CAAkB,CAAkB;MACxC,CAAA,GACN,kBAAC,GAAD;OAAM,IAAG;OAAO,UAAS;OAAU,OAAO,IAAO,aAAa;iBAC3D,EAAO,WAAW;MACf,CAAA,CACA;QAPK,CAOL;IAEZ,CAAC,CACK;;GAEP,EAAO,UACN,kBAAA,GAAA,EAAA,UAAA,CACE,kBAAC,GAAD;IAAK,GAAE;IAAM,IAAG;IAAW,IAAG;IAAU,IAAG;GAAW,CAAA,GACtD,kBAAC,GAAD;IAAM,IAAG;IAAO,UAAS;IAAM,OAAM;IAAW,OAAO,EAAE,YAAY,EAAE;cACpE,EAAO;GACJ,CAAA,CACN,EAAA,CAAA;EAED;;AAET"}
|
|
1
|
+
{"version":3,"file":"SupplierRatingBreakdown.js","names":[],"sources":["../../../src/components/supplier-rating-badge/SupplierRatingBreakdown.tsx"],"sourcesContent":["import { CheckCircleIcon, XCircleIcon } from '@heroicons/react/24/outline'\nimport { Box, HStack, VStack } from '@stokelp/styled-system/jsx'\n\nimport { Icon, Text } from '~/components'\n\nexport const SUPPLIER_RATING_MAX = 5\n\nexport type SupplierRatingComponentKey = 'responseRate' | 'responseDelay' | 'completion'\n\nexport type SupplierRatingCompletionKey =\n | 'profile'\n | 'location'\n | 'contacts'\n | 'legalBanking'\n | 'sector'\n | 'certificate'\n\nexport type SupplierRatingCompletion = Record<SupplierRatingCompletionKey, boolean>\n\nexport type SupplierRating = {\n /** Overall note out of 5. Absent when insufficientData is true. */\n overall?: number\n /** Response-rate sub-score, 0..1 (note calc only). Absent when insufficientData is true. */\n responseRateScore?: number\n /** Response-delay sub-score, 0..1 (note calc + colours the delay row). Absent when insufficientData is true. */\n responseDelayScore?: number\n /** Average response delay in MINUTES, for display. Absent when insufficientData is true. */\n responseDelayMinutes?: number\n /** Account-completion sub-score, 0..1. Always present. */\n completionScore: number\n /** True when the supplier has too few interactions for a reliable note. */\n insufficientData: boolean\n /** Completion checklist shown in the breakdown. */\n completion: SupplierRatingCompletion\n}\n\nexport type SupplierRatingLabels = {\n title: string\n /** Neutral state shown instead of a note when data is insufficient. */\n insufficientData: string\n /** Section heading above the sub-scores. */\n componentsTitle: string\n /** Section heading above the completion checklist. */\n completionTitle: string\n /** Value shown when a component has no data yet (e.g. \"—\"). */\n notAvailable: string\n /** Unit suffixes for the average response-delay value. */\n units: { minutes: string; hours: string; days: string }\n components: Record<SupplierRatingComponentKey, string>\n completion: Record<SupplierRatingCompletionKey, string>\n footer?: string\n}\n\nexport const DEFAULT_SUPPLIER_RATING_LABELS: SupplierRatingLabels = {\n title: 'Note fournisseur',\n insufficientData: 'Non noté',\n componentsTitle: 'Détail de la note',\n completionTitle: 'Complétion du compte',\n notAvailable: '—',\n units: { minutes: 'min', hours: 'h', days: 'j' },\n components: {\n responseRate: 'Taux de réponse',\n responseDelay: 'Délai de réponse',\n completion: 'Complétion du compte',\n },\n completion: {\n profile: 'Profil (photo et description)',\n location: 'Localisation',\n contacts: 'Contact',\n legalBanking: 'Coordonnées légales et bancaires',\n sector: \"Secteur d'activité\",\n certificate: 'Certificat',\n },\n}\n\nconst COMPLETION_ORDER: SupplierRatingCompletionKey[] = [\n 'profile',\n 'location',\n 'contacts',\n 'legalBanking',\n 'sector',\n 'certificate',\n]\n\nexport function formatOverall(overall: number): string {\n return overall.toFixed(1).replace('.', ',')\n}\n\n/** Average response delay: minutes → \"45 min\" / \"18 h\" / \"2,5 j\". */\nexport function formatResponseDelay(minutes: number, units: SupplierRatingLabels['units']): string {\n if (minutes < 60) return `${Math.round(minutes)} ${units.minutes}`\n const hours = minutes / 60\n if (hours < 48) return `${Math.round(hours)} ${units.hours}`\n const days = hours / 24\n return `${days.toFixed(1).replace('.', ',')} ${units.days}`\n}\n\nexport function getHeadlineColor(overall: number): string {\n const ratio = overall / SUPPLIER_RATING_MAX\n if (ratio >= 0.7) return '#3B6D11'\n if (ratio >= 0.4) return '#854F0B'\n return '#A32D2D'\n}\n\nfunction getBarColor(ratioPercent: number): string {\n if (ratioPercent >= 70) return '#639922'\n if (ratioPercent >= 40) return '#BA7517'\n return '#E24B4A'\n}\n\ntype ComponentRow = {\n key: SupplierRatingComponentKey\n value: string\n /** 0..100 bar fill, or null when there is no data. */\n barPercent: number | null\n /** Bar/value colour, or undefined for the neutral (no-data) state. */\n color?: string\n}\n\ntype SupplierRatingBreakdownProps = {\n rating: SupplierRating\n /** Original response rate (0..100), displayed as the \"Taux de réponse\" value. */\n responseRate?: number\n labels?: Partial<SupplierRatingLabels>\n}\n\nexport const SupplierRatingBreakdown = ({ rating, responseRate, labels: labelsProp }: SupplierRatingBreakdownProps) => {\n const labels: SupplierRatingLabels = {\n ...DEFAULT_SUPPLIER_RATING_LABELS,\n ...labelsProp,\n units: { ...DEFAULT_SUPPLIER_RATING_LABELS.units, ...labelsProp?.units },\n components: { ...DEFAULT_SUPPLIER_RATING_LABELS.components, ...labelsProp?.components },\n completion: { ...DEFAULT_SUPPLIER_RATING_LABELS.completion, ...labelsProp?.completion },\n }\n\n const hasResponseRate = responseRate != null\n const hasDelay = rating.responseDelayMinutes != null\n const delayPercent = rating.responseDelayScore != null ? Math.round(rating.responseDelayScore * 100) : null\n const completionPercent = Math.round(rating.completionScore * 100)\n\n const rows: ComponentRow[] = [\n {\n key: 'responseRate',\n value: hasResponseRate ? `${Math.round(responseRate)} %` : labels.notAvailable,\n barPercent: hasResponseRate ? Math.round(responseRate) : null,\n color: hasResponseRate ? getBarColor(Math.round(responseRate)) : undefined,\n },\n {\n key: 'responseDelay',\n value: hasDelay ? formatResponseDelay(rating.responseDelayMinutes as number, labels.units) : labels.notAvailable,\n barPercent: delayPercent,\n color: delayPercent != null ? getBarColor(delayPercent) : undefined,\n },\n {\n key: 'completion',\n value: `${completionPercent} %`,\n barPercent: completionPercent,\n color: getBarColor(completionPercent),\n },\n ]\n\n return (\n <Box\n bg=\"white\"\n borderRadius=\"radius-8\"\n p=\"space-16\"\n minW=\"240px\"\n maxW=\"260px\"\n css={{ '& *': { fontFamily: 'inherit' } }}\n >\n <HStack justify=\"space-between\" alignItems=\"baseline\" mb=\"space-8\">\n <Text as=\"span\" fontSize=\"body.md\" fontWeight=\"bold\">\n {labels.title}\n </Text>\n {rating.insufficientData || rating.overall == null ? (\n <Text as=\"span\" fontSize=\"body.sm\" fontWeight=\"medium\" color=\"grey.400\">\n {labels.insufficientData}\n </Text>\n ) : (\n <Text as=\"span\" fontSize=\"body.lg\" fontWeight=\"medium\" style={{ color: getHeadlineColor(rating.overall) }}>\n {formatOverall(rating.overall)} / {SUPPLIER_RATING_MAX} ★\n </Text>\n )}\n </HStack>\n\n <Box h=\"1px\" bg=\"grey.100\" mb=\"space-8\" />\n\n <VStack alignItems=\"stretch\" gap=\"space-8\" mb=\"space-8\">\n <Text as=\"span\" fontSize=\"body.sm\" fontWeight=\"bold\" color=\"grey.400\">\n {labels.componentsTitle}\n </Text>\n {rows.map(row => (\n <VStack key={row.key} alignItems=\"stretch\" gap=\"space-2\">\n <HStack justify=\"space-between\" alignItems=\"baseline\" gap=\"space-8\">\n <Text as=\"span\" fontSize=\"body.sm\" color=\"grey.500\">\n {labels.components[row.key]}\n </Text>\n <Text\n as=\"span\"\n fontSize=\"body.sm\"\n fontWeight=\"medium\"\n whiteSpace=\"nowrap\"\n style={{ color: row.color }}\n color={row.color ? undefined : 'grey.300'}\n >\n {row.value}\n </Text>\n </HStack>\n <Box h=\"3px\" bg=\"grey.100\" borderRadius=\"full\" overflow=\"hidden\">\n <Box\n h=\"100%\"\n borderRadius=\"full\"\n style={{\n width: row.barPercent != null ? `${row.barPercent}%` : '0%',\n background: row.color ?? 'transparent',\n }}\n />\n </Box>\n </VStack>\n ))}\n </VStack>\n\n <Box h=\"1px\" bg=\"grey.100\" mb=\"space-8\" />\n\n <VStack alignItems=\"stretch\" gap=\"space-4\">\n <Text as=\"span\" fontSize=\"body.sm\" fontWeight=\"bold\" color=\"grey.400\">\n {labels.completionTitle}\n </Text>\n {COMPLETION_ORDER.map(key => {\n const done = rating.completion[key]\n return (\n <HStack key={key} alignItems=\"center\" gap=\"space-8\">\n <Icon size=\"sm\" color={done ? 'success.500' : 'grey.300'} flexShrink=\"0\">\n {done ? <CheckCircleIcon /> : <XCircleIcon />}\n </Icon>\n <Text as=\"span\" fontSize=\"body.sm\" color={done ? 'grey.500' : 'grey.400'}>\n {labels.completion[key]}\n </Text>\n </HStack>\n )\n })}\n </VStack>\n\n {labels.footer && (\n <>\n <Box h=\"1px\" bg=\"grey.100\" mt=\"space-8\" mb=\"space-8\" />\n <Text as=\"span\" fontSize=\"9px\" color=\"grey.300\" style={{ lineHeight: 1 }}>\n {labels.footer}\n </Text>\n </>\n )}\n </Box>\n )\n}\n"],"mappings":";;;;;;;;AAKA,IAAa,IAAsB,GAgDtB,IAAuD;CAClE,OAAO;CACP,kBAAkB;CAClB,iBAAiB;CACjB,iBAAiB;CACjB,cAAc;CACd,OAAO;EAAE,SAAS;EAAO,OAAO;EAAK,MAAM;CAAI;CAC/C,YAAY;EACV,cAAc;EACd,eAAe;EACf,YAAY;CACd;CACA,YAAY;EACV,SAAS;EACT,UAAU;EACV,UAAU;EACV,cAAc;EACd,QAAQ;EACR,aAAa;CACf;AACF,GAEM,IAAkD;CACtD;CACA;CACA;CACA;CACA;CACA;AACF;AAEA,SAAgB,EAAc,GAAyB;CACrD,OAAO,EAAQ,QAAQ,CAAC,EAAE,QAAQ,KAAK,GAAG;AAC5C;AAGA,SAAgB,EAAoB,GAAiB,GAA8C;CACjG,IAAI,IAAU,IAAI,OAAO,GAAG,KAAK,MAAM,CAAO,EAAE,GAAG,EAAM;CACzD,IAAM,IAAQ,IAAU;CAGxB,OAFI,IAAQ,KAAW,GAAG,KAAK,MAAM,CAAK,EAAE,GAAG,EAAM,UAE9C,IAD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A8B,OAAvB,GAAG,EAAI,WAAW;QAClD,YAAY,EAAI,SAAS;OAC3B;MACD,CAAA;KACE,CAAA,CACC;OA1BK,EAAI,GA0BT,CACT,CACK;;GAER,kBAAC,GAAD;IAAK,GAAE;IAAM,IAAG;IAAW,IAAG;GAAW,CAAA;GAEzC,kBAAC,GAAD;IAAQ,YAAW;IAAU,KAAI;cAAjC,CACE,kBAAC,GAAD;KAAM,IAAG;KAAO,UAAS;KAAU,YAAW;KAAO,OAAM;eACxD,EAAO;IACJ,CAAA,GACL,EAAiB,KAAI,MAAO;KAC3B,IAAM,IAAO,EAAO,WAAW;KAC/B,OACE,kBAAC,GAAD;MAAkB,YAAW;MAAS,KAAI;gBAA1C,CACE,kBAAC,GAAD;OAAM,MAAK;OAAK,OAAO,IAAO,gBAAgB;OAAY,YAAW;iBAC3D,EAAP,IAAQ,IAAsB,GAAvB,CAAkB,CAAkB;MACxC,CAAA,GACN,kBAAC,GAAD;OAAM,IAAG;OAAO,UAAS;OAAU,OAAO,IAAO,aAAa;iBAC3D,EAAO,WAAW;MACf,CAAA,CACA;QAPK,CAOL;IAEZ,CAAC,CACK;;GAEP,EAAO,UACN,kBAAA,GAAA,EAAA,UAAA,CACE,kBAAC,GAAD;IAAK,GAAE;IAAM,IAAG;IAAW,IAAG;IAAU,IAAG;GAAW,CAAA,GACtD,kBAAC,GAAD;IAAM,IAAG;IAAO,UAAS;IAAM,OAAM;IAAW,OAAO,EAAE,YAAY,EAAE;cACpE,EAAO;GACJ,CAAA,CACN,EAAA,CAAA;EAED;;AAET"}
|
package/dist/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use client";Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});/* empty css */const e=require("./components/accordion/Accordion.cjs"),t=require("./components/button/Button.cjs"),n=require("./components/checkbox/Checkbox.cjs"),r=require("./components/icon-button/IconButton.cjs"),i=require("./components/drawer/Drawer.cjs"),ee=require("./components/form/FormControl.cjs"),a=require("./components/tooltip/Tooltip.cjs"),o=require("./components/form/FormLabel.cjs"),s=require("./components/form/FormHelperText.cjs"),c=require("./components/heading/Heading.cjs"),l=require("./components/switch/Switch.cjs"),u=require("./components/text/Text.cjs"),d=require("./components/textarea/Textarea.cjs"),f=require("./components/tabs/Tabs.cjs"),p=require("./components/select/Select.cjs"),te=require("./components/select-language/SelectLanguage.cjs"),ne=require("./components/input/Input.cjs"),m=require("./components/input/HighlightedInput.cjs"),re=require("./components/input/InputAddon.cjs"),h=require("./components/input/InputGroup.cjs"),g=require("./components/input/PhoneNumberInput.cjs"),_=require("./components/box/Box.cjs"),v=require("./components/date-picker/DatePicker.cjs"),y=require("./components/tag/Tag.cjs"),b=require("./components/radio-button-group/RadioButtonGroup.cjs"),x=require("./components/radio-group/RadioGroup.cjs"),S=require("./components/chip/Chip.cjs"),C=require("./components/action-card/ActionCard.cjs"),w=require("./components/alert/Alert.cjs"),T=require("./components/table/Table.cjs"),E=require("./components/breadcrumb/Breadcrumb.cjs"),D=require("./components/popover/Popover.cjs"),O=require("./components/pagination/Pagination.cjs"),k=require("./components/illustration/Illustration.cjs"),A=require("./components/button-filter/ButtonFilter.cjs"),j=require("./components/status-tag-select/StatusTagSelect.cjs"),M=require("./components/switch-card/namespace.cjs"),N=require("./components/radio-card-group/namespace.cjs"),P=require("./components/checkbox-card/namespace.cjs"),F=require("./components/combobox/Combobox.cjs"),I=require("./components/icon/Icon.cjs"),L=require("./components/collapsible/styled.cjs"),ie=require("./components/dialog/styled.cjs"),R=require("./components/avatar/styled.cjs"),z=require("./components/menu/Menu.cjs"),B=require("./components/flag/styled.cjs"),V=require("./components/origin-select/OriginSelect.cjs"),H=require("./components/chat/ChatMessage.cjs"),U=require("./components/chat/ChatDocumentMessage.cjs"),W=require("./components/chat/ChatProfileAvatar.cjs"),G=require("./components/chat/Chat.cjs"),K=require("./components/chat/ChatScoreBreakdown.cjs"),q=require("./components/chat/ChatTextInput.cjs"),J=require("./components/supplier-rating-badge/SupplierRatingBreakdown.cjs"),Y=require("./components/supplier-rating-badge/SupplierRatingBadge.cjs"),ae=require("./components/app/price-tag/PriceTag.cjs"),oe=require("./components/app/product-card-catalog/styled.cjs"),se=require("./components/app/navigation/AppNavigation.cjs"),ce=require("./components/app/navigation/language-select/AppNavigationLanguageSelect.cjs"),le=require("./components/app/mobile-navigation/MobileNavigation.cjs"),X=require("./components/app/mobile-card/MobileCardShell.cjs"),ue=require("./components/app/mobile-card/MobileCardHeader.cjs"),de=require("./components/app/mobile-card/MobileCardNotificationBadge.cjs"),fe=require("./components/app/mobile-card/MobileCardEntityRow.cjs"),Z=require("./components/app/mobile-card/MobileCardSkeleton.cjs"),pe=require("./preset.cjs");let Q=require("@ark-ui/react"),$=require("react-phone-number-input");exports.Accordion=e.Accordion,exports.AccordionItem=e.AccordionItem,exports.AccordionItemContent=e.AccordionItemContent,exports.AccordionItemIndicator=e.AccordionItemIndicator,exports.AccordionItemTrigger=e.AccordionItemTrigger,exports.ActionCard=C.ActionCard,exports.ActionCardDescription=C.ActionCardDescription,exports.ActionCardTitle=C.ActionCardTitle,exports.Alert=w.Alert,Object.defineProperty(exports,"AppNavigation",{enumerable:!0,get:function(){return se.AppNavigation_exports}}),exports.AppNavigationLanguageSelect=ce.AppNavigationLanguageSelect,Object.defineProperty(exports,"Avatar",{enumerable:!0,get:function(){return R.styled_exports}}),exports.Box=_.Box,exports.Breadcrumb=E.Breadcrumb,exports.BreadcrumbItem=E.BreadcrumbItem,exports.BreadcrumbLink=E.BreadcrumbLink,exports.Button=t.Button,exports.ButtonFilter=A.ButtonFilter,Object.defineProperty(exports,"Chat",{enumerable:!0,get:function(){return G.Chat_exports}}),exports.ChatDocumentMessage=U.ChatDocumentMessage,exports.ChatMessage=H.ChatMessage,exports.ChatProfileAvatar=W.ChatProfileAvatar,exports.ChatScoreBreakdown=K.ChatScoreBreakdown,exports.ChatTextInput=q.ChatTextInput,exports.Checkbox=n.Checkbox,Object.defineProperty(exports,"CheckboxCard",{enumerable:!0,get:function(){return P.namespace_exports}}),exports.CheckboxGroup=n.CheckboxGroup,exports.Chip=S.Chip,exports.ChipAvatar=S.ChipAvatar,exports.ChipClearTrigger=S.ChipClearTrigger,exports.ChipLabel=S.ChipLabel,Object.defineProperty(exports,"Collapsible",{enumerable:!0,get:function(){return L.styled_exports}}),exports.Combobox=F.Combobox,exports.DEFAULT_SUPPLIER_RATING_LABELS=J.DEFAULT_SUPPLIER_RATING_LABELS,exports.DatePicker=v.DatePicker,Object.defineProperty(exports,"Dialog",{enumerable:!0,get:function(){return ie.styled_exports}}),exports.Drawer=i.Drawer,exports.DrawerBody=i.DrawerBody,exports.DrawerCloseTrigger=i.DrawerCloseTrigger,exports.DrawerContent=i.DrawerContent,exports.DrawerContext=i.DrawerContext,exports.DrawerFooter=i.DrawerFooter,exports.DrawerHeader=i.DrawerHeader,exports.DrawerTitle=i.DrawerTitle,exports.DrawerTrigger=i.DrawerTrigger,exports.Flag=B.Flag,exports.FlagCountryCodes=B.FlagCountryCodes,exports.FormControl=ee.FormControl,exports.FormHelperText=s.FormHelperText,exports.FormLabel=o.FormLabel,exports.Heading=c.Heading,exports.Highlight=m.Highlight,exports.HighlightedInput=m.HighlightedInput,exports.Icon=I.Icon,exports.IconButton=r.IconButton,exports.Illustration=k.Illustration,exports.Input=ne.Input,exports.InputAddon=re.InputAddon,exports.InputGroup=h.InputGroup,exports.InputSlot=m.InputSlot,Object.defineProperty(exports,"Menu",{enumerable:!0,get:function(){return z.Menu_exports}}),exports.MobileCardEntityRow=fe.MobileCardEntityRow,exports.MobileCardHeader=ue.MobileCardHeader,exports.MobileCardNotificationBadge=de.MobileCardNotificationBadge,exports.MobileCardShell=X.MobileCardShell,exports.MobileCardSkeleton=Z.MobileCardSkeleton,exports.MobileCardSkeletonList=Z.MobileCardSkeletonList,Object.defineProperty(exports,"MobileNavigation",{enumerable:!0,get:function(){return le.MobileNavigation_exports}}),exports.OriginSelect=V.OriginSelect,exports.Pagination=O.Pagination,exports.PhoneNumberInput=g.PhoneNumberInput,exports.Popover=D.Popover,exports.PopoverAnchor=D.PopoverAnchor,exports.PopoverCloseTrigger=D.PopoverCloseTrigger,exports.PopoverContent=D.PopoverContent,exports.PopoverContext=D.PopoverContext,exports.PopoverTrigger=D.PopoverTrigger,exports.PriceTag=ae.PriceTag,Object.defineProperty(exports,"ProductCardCatalog",{enumerable:!0,get:function(){return oe.styled_exports}}),exports.RadioButtonGroup=b.RadioButtonGroup,exports.RadioButtonGroupItem=b.RadioButtonGroupItem,exports.RadioButtonGroupLabel=b.RadioButtonGroupLabel,Object.defineProperty(exports,"RadioCardGroup",{enumerable:!0,get:function(){return N.namespace_exports}}),exports.RadioGroup=x.RadioGroup,exports.RadioGroupItem=x.RadioGroupItem,exports.RadioGroupLabel=x.RadioGroupLabel,exports.Renderer=m.Renderer,exports.Root=m.Root,exports.SUPPLIER_RATING_MAX=J.SUPPLIER_RATING_MAX,exports.Select=p.Select,exports.SelectLanguage=te.SelectLanguage,exports.SkeletonBlock=Z.SkeletonBlock,exports.StatusTagSelect=j.StatusTagSelect,exports.SupplierRatingBadge=Y.SupplierRatingBadge,exports.SupplierRatingBreakdown=J.SupplierRatingBreakdown,exports.Switch=l.Switch,Object.defineProperty(exports,"SwitchCard",{enumerable:!0,get:function(){return M.namespace_exports}}),exports.Table=T.Table,exports.TableContainer=T.TableContainer,exports.TableEmptyRow=T.TableEmptyRow,exports.TableGroupTitle=T.TableGroupTitle,exports.Tabs=f.Tabs,exports.TabsChip=f.TabsChip,exports.TabsContent=f.TabsContent,exports.TabsList=f.TabsList,exports.TabsTrigger=f.TabsTrigger,exports.Tag=y.Tag,exports.Tbody=T.Tbody,exports.Td=T.Td,exports.Text=u.Text,exports.Textarea=d.Textarea,exports.Th=T.Th,exports.Thead=T.Thead,exports.Tooltip=a.Tooltip,exports.Tr=T.Tr,Object.defineProperty(exports,"createListCollection",{enumerable:!0,get:function(){return Q.createListCollection}}),Object.defineProperty(exports,"createToaster",{enumerable:!0,get:function(){return Q.createToaster}}),exports.formatOverall=J.formatOverall,Object.defineProperty(exports,"formatPhoneNumber",{enumerable:!0,get:function(){return $.formatPhoneNumber}}),Object.defineProperty(exports,"formatPhoneNumberIntl",{enumerable:!0,get:function(){return $.formatPhoneNumberIntl}}),exports.formatResponseDelay=J.formatResponseDelay,Object.defineProperty(exports,"getCountries",{enumerable:!0,get:function(){return $.getCountries}}),Object.defineProperty(exports,"getCountryCallingCode",{enumerable:!0,get:function(){return $.getCountryCallingCode}}),exports.getHeadlineColor=J.getHeadlineColor,Object.defineProperty(exports,"isPossiblePhoneNumber",{enumerable:!0,get:function(){return $.isPossiblePhoneNumber}}),Object.defineProperty(exports,"isSupportedCountry",{enumerable:!0,get:function(){return $.isSupportedCountry}}),Object.defineProperty(exports,"isValidPhoneNumber",{enumerable:!0,get:function(){return $.isValidPhoneNumber}}),Object.defineProperty(exports,"parseColor",{enumerable:!0,get:function(){return Q.parseColor}}),Object.defineProperty(exports,"parseDate",{enumerable:!0,get:function(){return Q.parseDate}}),Object.defineProperty(exports,"parsePhoneNumber",{enumerable:!0,get:function(){return $.parsePhoneNumber}}),exports.preset=pe.preset,Object.defineProperty(exports,"useAccordion",{enumerable:!0,get:function(){return Q.useAccordion}});
|
|
1
|
+
"use client";Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});/* empty css */const e=require("./components/accordion/Accordion.cjs"),t=require("./components/button/Button.cjs"),n=require("./components/checkbox/Checkbox.cjs"),r=require("./components/icon-button/IconButton.cjs"),i=require("./components/drawer/Drawer.cjs"),a=require("./components/form/FormControl.cjs"),ee=require("./components/tooltip/Tooltip.cjs"),o=require("./components/form/FormLabel.cjs"),s=require("./components/form/FormHelperText.cjs"),c=require("./components/heading/Heading.cjs"),l=require("./components/switch/Switch.cjs"),u=require("./components/text/Text.cjs"),d=require("./components/textarea/Textarea.cjs"),f=require("./components/tabs/Tabs.cjs"),p=require("./components/steps/Steps.cjs"),m=require("./components/select/Select.cjs"),te=require("./components/select-language/SelectLanguage.cjs"),ne=require("./components/input/Input.cjs"),h=require("./components/input/HighlightedInput.cjs"),re=require("./components/input/InputAddon.cjs"),g=require("./components/input/InputGroup.cjs"),_=require("./components/input/PhoneNumberInput.cjs"),v=require("./components/box/Box.cjs"),y=require("./components/date-picker/DatePicker.cjs"),b=require("./components/tag/Tag.cjs"),x=require("./components/radio-button-group/RadioButtonGroup.cjs"),S=require("./components/radio-group/RadioGroup.cjs"),C=require("./components/chip/Chip.cjs"),w=require("./components/action-card/ActionCard.cjs"),T=require("./components/alert/Alert.cjs"),E=require("./components/table/Table.cjs"),D=require("./components/breadcrumb/Breadcrumb.cjs"),O=require("./components/popover/Popover.cjs"),k=require("./components/pagination/Pagination.cjs"),A=require("./components/illustration/Illustration.cjs"),j=require("./components/button-filter/ButtonFilter.cjs"),M=require("./components/status-tag-select/StatusTagSelect.cjs"),N=require("./components/switch-card/namespace.cjs"),P=require("./components/radio-card-group/namespace.cjs"),F=require("./components/checkbox-card/namespace.cjs"),I=require("./components/combobox/Combobox.cjs"),L=require("./components/icon/Icon.cjs"),R=require("./components/collapsible/styled.cjs"),ie=require("./components/dialog/styled.cjs"),z=require("./components/avatar/styled.cjs"),B=require("./components/menu/Menu.cjs"),V=require("./components/flag/styled.cjs"),H=require("./components/origin-select/OriginSelect.cjs"),U=require("./components/chat/ChatMessage.cjs"),W=require("./components/chat/ChatDocumentMessage.cjs"),G=require("./components/chat/ChatProfileAvatar.cjs"),K=require("./components/chat/Chat.cjs"),q=require("./components/chat/ChatScoreBreakdown.cjs"),J=require("./components/chat/ChatTextInput.cjs"),Y=require("./components/supplier-rating-badge/SupplierRatingBreakdown.cjs"),ae=require("./components/supplier-rating-badge/SupplierRatingBadge.cjs"),oe=require("./components/app/price-tag/PriceTag.cjs"),se=require("./components/app/product-card-catalog/styled.cjs"),ce=require("./components/app/navigation/AppNavigation.cjs"),le=require("./components/app/navigation/language-select/AppNavigationLanguageSelect.cjs"),X=require("./components/app/mobile-navigation/MobileNavigation.cjs"),ue=require("./components/app/mobile-card/MobileCardShell.cjs"),de=require("./components/app/mobile-card/MobileCardHeader.cjs"),fe=require("./components/app/mobile-card/MobileCardNotificationBadge.cjs"),pe=require("./components/app/mobile-card/MobileCardEntityRow.cjs"),Z=require("./components/app/mobile-card/MobileCardSkeleton.cjs"),me=require("./preset.cjs");let Q=require("@ark-ui/react"),$=require("react-phone-number-input");exports.Accordion=e.Accordion,exports.AccordionItem=e.AccordionItem,exports.AccordionItemContent=e.AccordionItemContent,exports.AccordionItemIndicator=e.AccordionItemIndicator,exports.AccordionItemTrigger=e.AccordionItemTrigger,exports.ActionCard=w.ActionCard,exports.ActionCardDescription=w.ActionCardDescription,exports.ActionCardTitle=w.ActionCardTitle,exports.Alert=T.Alert,Object.defineProperty(exports,"AppNavigation",{enumerable:!0,get:function(){return ce.AppNavigation_exports}}),exports.AppNavigationLanguageSelect=le.AppNavigationLanguageSelect,Object.defineProperty(exports,"Avatar",{enumerable:!0,get:function(){return z.styled_exports}}),exports.Box=v.Box,exports.Breadcrumb=D.Breadcrumb,exports.BreadcrumbItem=D.BreadcrumbItem,exports.BreadcrumbLink=D.BreadcrumbLink,exports.Button=t.Button,exports.ButtonFilter=j.ButtonFilter,Object.defineProperty(exports,"Chat",{enumerable:!0,get:function(){return K.Chat_exports}}),exports.ChatDocumentMessage=W.ChatDocumentMessage,exports.ChatMessage=U.ChatMessage,exports.ChatProfileAvatar=G.ChatProfileAvatar,exports.ChatScoreBreakdown=q.ChatScoreBreakdown,exports.ChatTextInput=J.ChatTextInput,exports.Checkbox=n.Checkbox,Object.defineProperty(exports,"CheckboxCard",{enumerable:!0,get:function(){return F.namespace_exports}}),exports.CheckboxGroup=n.CheckboxGroup,exports.Chip=C.Chip,exports.ChipAvatar=C.ChipAvatar,exports.ChipClearTrigger=C.ChipClearTrigger,exports.ChipLabel=C.ChipLabel,Object.defineProperty(exports,"Collapsible",{enumerable:!0,get:function(){return R.styled_exports}}),exports.Combobox=I.Combobox,exports.DEFAULT_SUPPLIER_RATING_LABELS=Y.DEFAULT_SUPPLIER_RATING_LABELS,exports.DatePicker=y.DatePicker,Object.defineProperty(exports,"Dialog",{enumerable:!0,get:function(){return ie.styled_exports}}),exports.Drawer=i.Drawer,exports.DrawerBody=i.DrawerBody,exports.DrawerCloseTrigger=i.DrawerCloseTrigger,exports.DrawerContent=i.DrawerContent,exports.DrawerContext=i.DrawerContext,exports.DrawerFooter=i.DrawerFooter,exports.DrawerHeader=i.DrawerHeader,exports.DrawerTitle=i.DrawerTitle,exports.DrawerTrigger=i.DrawerTrigger,exports.Flag=V.Flag,exports.FlagCountryCodes=V.FlagCountryCodes,exports.FormControl=a.FormControl,exports.FormHelperText=s.FormHelperText,exports.FormLabel=o.FormLabel,exports.Heading=c.Heading,exports.Highlight=h.Highlight,exports.HighlightedInput=h.HighlightedInput,exports.Icon=L.Icon,exports.IconButton=r.IconButton,exports.Illustration=A.Illustration,exports.Input=ne.Input,exports.InputAddon=re.InputAddon,exports.InputGroup=g.InputGroup,exports.InputSlot=h.InputSlot,Object.defineProperty(exports,"Menu",{enumerable:!0,get:function(){return B.Menu_exports}}),exports.MobileCardEntityRow=pe.MobileCardEntityRow,exports.MobileCardHeader=de.MobileCardHeader,exports.MobileCardNotificationBadge=fe.MobileCardNotificationBadge,exports.MobileCardShell=ue.MobileCardShell,exports.MobileCardSkeleton=Z.MobileCardSkeleton,exports.MobileCardSkeletonList=Z.MobileCardSkeletonList,Object.defineProperty(exports,"MobileNavigation",{enumerable:!0,get:function(){return X.MobileNavigation_exports}}),exports.OriginSelect=H.OriginSelect,exports.Pagination=k.Pagination,exports.PhoneNumberInput=_.PhoneNumberInput,exports.Popover=O.Popover,exports.PopoverAnchor=O.PopoverAnchor,exports.PopoverCloseTrigger=O.PopoverCloseTrigger,exports.PopoverContent=O.PopoverContent,exports.PopoverContext=O.PopoverContext,exports.PopoverTrigger=O.PopoverTrigger,exports.PriceTag=oe.PriceTag,Object.defineProperty(exports,"ProductCardCatalog",{enumerable:!0,get:function(){return se.styled_exports}}),exports.RadioButtonGroup=x.RadioButtonGroup,exports.RadioButtonGroupItem=x.RadioButtonGroupItem,exports.RadioButtonGroupLabel=x.RadioButtonGroupLabel,Object.defineProperty(exports,"RadioCardGroup",{enumerable:!0,get:function(){return P.namespace_exports}}),exports.RadioGroup=S.RadioGroup,exports.RadioGroupItem=S.RadioGroupItem,exports.RadioGroupLabel=S.RadioGroupLabel,exports.Renderer=h.Renderer,exports.Root=h.Root,exports.SUPPLIER_RATING_MAX=Y.SUPPLIER_RATING_MAX,exports.Select=m.Select,exports.SelectLanguage=te.SelectLanguage,exports.SkeletonBlock=Z.SkeletonBlock,exports.StatusTagSelect=M.StatusTagSelect,exports.Steps=p.Steps,exports.StepsContent=p.StepsContent,exports.StepsIndicator=p.StepsIndicator,exports.StepsItem=p.StepsItem,exports.StepsList=p.StepsList,exports.StepsSeparator=p.StepsSeparator,exports.StepsTrigger=p.StepsTrigger,exports.SupplierRatingBadge=ae.SupplierRatingBadge,exports.SupplierRatingBreakdown=Y.SupplierRatingBreakdown,exports.Switch=l.Switch,Object.defineProperty(exports,"SwitchCard",{enumerable:!0,get:function(){return N.namespace_exports}}),exports.Table=E.Table,exports.TableContainer=E.TableContainer,exports.TableEmptyRow=E.TableEmptyRow,exports.TableGroupTitle=E.TableGroupTitle,exports.Tabs=f.Tabs,exports.TabsChip=f.TabsChip,exports.TabsContent=f.TabsContent,exports.TabsList=f.TabsList,exports.TabsTrigger=f.TabsTrigger,exports.Tag=b.Tag,exports.Tbody=E.Tbody,exports.Td=E.Td,exports.Text=u.Text,exports.Textarea=d.Textarea,exports.Th=E.Th,exports.Thead=E.Thead,exports.Tooltip=ee.Tooltip,exports.Tr=E.Tr,Object.defineProperty(exports,"createListCollection",{enumerable:!0,get:function(){return Q.createListCollection}}),Object.defineProperty(exports,"createToaster",{enumerable:!0,get:function(){return Q.createToaster}}),exports.formatOverall=Y.formatOverall,Object.defineProperty(exports,"formatPhoneNumber",{enumerable:!0,get:function(){return $.formatPhoneNumber}}),Object.defineProperty(exports,"formatPhoneNumberIntl",{enumerable:!0,get:function(){return $.formatPhoneNumberIntl}}),exports.formatResponseDelay=Y.formatResponseDelay,Object.defineProperty(exports,"getCountries",{enumerable:!0,get:function(){return $.getCountries}}),Object.defineProperty(exports,"getCountryCallingCode",{enumerable:!0,get:function(){return $.getCountryCallingCode}}),exports.getHeadlineColor=Y.getHeadlineColor,Object.defineProperty(exports,"isPossiblePhoneNumber",{enumerable:!0,get:function(){return $.isPossiblePhoneNumber}}),Object.defineProperty(exports,"isSupportedCountry",{enumerable:!0,get:function(){return $.isSupportedCountry}}),Object.defineProperty(exports,"isValidPhoneNumber",{enumerable:!0,get:function(){return $.isValidPhoneNumber}}),Object.defineProperty(exports,"parseColor",{enumerable:!0,get:function(){return Q.parseColor}}),Object.defineProperty(exports,"parseDate",{enumerable:!0,get:function(){return Q.parseDate}}),Object.defineProperty(exports,"parsePhoneNumber",{enumerable:!0,get:function(){return $.parsePhoneNumber}}),exports.preset=me.preset,Object.defineProperty(exports,"useAccordion",{enumerable:!0,get:function(){return Q.useAccordion}});
|
package/dist/index.js
CHANGED
|
@@ -14,58 +14,59 @@ import { Switch as w } from "./components/switch/Switch.js";
|
|
|
14
14
|
import { Text as T } from "./components/text/Text.js";
|
|
15
15
|
import { Textarea as E } from "./components/textarea/Textarea.js";
|
|
16
16
|
import { Tabs as D, TabsChip as O, TabsContent as k, TabsList as A, TabsTrigger as j } from "./components/tabs/Tabs.js";
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
28
|
-
import {
|
|
29
|
-
import {
|
|
30
|
-
import {
|
|
31
|
-
import {
|
|
32
|
-
import {
|
|
33
|
-
import {
|
|
34
|
-
import {
|
|
35
|
-
import {
|
|
36
|
-
import {
|
|
37
|
-
import {
|
|
38
|
-
import {
|
|
39
|
-
import {
|
|
40
|
-
import { namespace_exports as
|
|
41
|
-
import { namespace_exports as
|
|
42
|
-
import {
|
|
43
|
-
import {
|
|
44
|
-
import {
|
|
45
|
-
import { styled_exports as
|
|
46
|
-
import { styled_exports as
|
|
47
|
-
import {
|
|
48
|
-
import {
|
|
49
|
-
import {
|
|
50
|
-
import {
|
|
51
|
-
import {
|
|
52
|
-
import {
|
|
53
|
-
import {
|
|
54
|
-
import {
|
|
55
|
-
import {
|
|
56
|
-
import {
|
|
57
|
-
import {
|
|
58
|
-
import {
|
|
59
|
-
import {
|
|
60
|
-
import {
|
|
61
|
-
import {
|
|
62
|
-
import {
|
|
63
|
-
import {
|
|
64
|
-
import {
|
|
65
|
-
import {
|
|
66
|
-
import {
|
|
67
|
-
import {
|
|
68
|
-
import {
|
|
69
|
-
import {
|
|
70
|
-
import {
|
|
71
|
-
|
|
17
|
+
import { Steps as M, StepsContent as N, StepsIndicator as P, StepsItem as F, StepsList as I, StepsSeparator as L, StepsTrigger as R } from "./components/steps/Steps.js";
|
|
18
|
+
import { Select as z } from "./components/select/Select.js";
|
|
19
|
+
import { SelectLanguage as B } from "./components/select-language/SelectLanguage.js";
|
|
20
|
+
import { Input as V } from "./components/input/Input.js";
|
|
21
|
+
import { Highlight as H, HighlightedInput as U, InputSlot as W, Renderer as G, Root as K } from "./components/input/HighlightedInput.js";
|
|
22
|
+
import { InputAddon as q } from "./components/input/InputAddon.js";
|
|
23
|
+
import { InputGroup as J } from "./components/input/InputGroup.js";
|
|
24
|
+
import { PhoneNumberInput as Y } from "./components/input/PhoneNumberInput.js";
|
|
25
|
+
import { Box as X } from "./components/box/Box.js";
|
|
26
|
+
import { DatePicker as Z } from "./components/date-picker/DatePicker.js";
|
|
27
|
+
import { Tag as Q } from "./components/tag/Tag.js";
|
|
28
|
+
import { RadioButtonGroup as $, RadioButtonGroupItem as ee, RadioButtonGroupLabel as te } from "./components/radio-button-group/RadioButtonGroup.js";
|
|
29
|
+
import { RadioGroup as ne, RadioGroupItem as re, RadioGroupLabel as ie } from "./components/radio-group/RadioGroup.js";
|
|
30
|
+
import { Chip as ae, ChipAvatar as oe, ChipClearTrigger as se, ChipLabel as ce } from "./components/chip/Chip.js";
|
|
31
|
+
import { ActionCard as le, ActionCardDescription as ue, ActionCardTitle as de } from "./components/action-card/ActionCard.js";
|
|
32
|
+
import { Alert as fe } from "./components/alert/Alert.js";
|
|
33
|
+
import { Table as pe, TableContainer as me, TableEmptyRow as he, TableGroupTitle as ge, Tbody as _e, Td as ve, Th as ye, Thead as be, Tr as xe } from "./components/table/Table.js";
|
|
34
|
+
import { Breadcrumb as Se, BreadcrumbItem as Ce, BreadcrumbLink as we } from "./components/breadcrumb/Breadcrumb.js";
|
|
35
|
+
import { Popover as Te, PopoverAnchor as Ee, PopoverCloseTrigger as De, PopoverContent as Oe, PopoverContext as ke, PopoverTrigger as Ae } from "./components/popover/Popover.js";
|
|
36
|
+
import { Pagination as je } from "./components/pagination/Pagination.js";
|
|
37
|
+
import { Illustration as Me } from "./components/illustration/Illustration.js";
|
|
38
|
+
import { ButtonFilter as Ne } from "./components/button-filter/ButtonFilter.js";
|
|
39
|
+
import { StatusTagSelect as Pe } from "./components/status-tag-select/StatusTagSelect.js";
|
|
40
|
+
import { namespace_exports as Fe } from "./components/switch-card/namespace.js";
|
|
41
|
+
import { namespace_exports as Ie } from "./components/radio-card-group/namespace.js";
|
|
42
|
+
import { namespace_exports as Le } from "./components/checkbox-card/namespace.js";
|
|
43
|
+
import { Combobox as Re } from "./components/combobox/Combobox.js";
|
|
44
|
+
import { Icon as ze } from "./components/icon/Icon.js";
|
|
45
|
+
import { styled_exports as Be } from "./components/collapsible/styled.js";
|
|
46
|
+
import { styled_exports as Ve } from "./components/dialog/styled.js";
|
|
47
|
+
import { styled_exports as He } from "./components/avatar/styled.js";
|
|
48
|
+
import { Menu_exports as Ue } from "./components/menu/Menu.js";
|
|
49
|
+
import { Flag as We, FlagCountryCodes as Ge } from "./components/flag/styled.js";
|
|
50
|
+
import { OriginSelect as Ke } from "./components/origin-select/OriginSelect.js";
|
|
51
|
+
import { ChatMessage as qe } from "./components/chat/ChatMessage.js";
|
|
52
|
+
import { ChatDocumentMessage as Je } from "./components/chat/ChatDocumentMessage.js";
|
|
53
|
+
import { ChatProfileAvatar as Ye } from "./components/chat/ChatProfileAvatar.js";
|
|
54
|
+
import { Chat_exports as Xe } from "./components/chat/Chat.js";
|
|
55
|
+
import { ChatScoreBreakdown as Ze } from "./components/chat/ChatScoreBreakdown.js";
|
|
56
|
+
import { ChatTextInput as Qe } from "./components/chat/ChatTextInput.js";
|
|
57
|
+
import { DEFAULT_SUPPLIER_RATING_LABELS as $e, SUPPLIER_RATING_MAX as et, SupplierRatingBreakdown as tt, formatOverall as nt, formatResponseDelay as rt, getHeadlineColor as it } from "./components/supplier-rating-badge/SupplierRatingBreakdown.js";
|
|
58
|
+
import { SupplierRatingBadge as at } from "./components/supplier-rating-badge/SupplierRatingBadge.js";
|
|
59
|
+
import { PriceTag as ot } from "./components/app/price-tag/PriceTag.js";
|
|
60
|
+
import { styled_exports as st } from "./components/app/product-card-catalog/styled.js";
|
|
61
|
+
import { AppNavigation_exports as ct } from "./components/app/navigation/AppNavigation.js";
|
|
62
|
+
import { AppNavigationLanguageSelect as lt } from "./components/app/navigation/language-select/AppNavigationLanguageSelect.js";
|
|
63
|
+
import { MobileNavigation_exports as ut } from "./components/app/mobile-navigation/MobileNavigation.js";
|
|
64
|
+
import { MobileCardShell as dt } from "./components/app/mobile-card/MobileCardShell.js";
|
|
65
|
+
import { MobileCardHeader as ft } from "./components/app/mobile-card/MobileCardHeader.js";
|
|
66
|
+
import { MobileCardNotificationBadge as pt } from "./components/app/mobile-card/MobileCardNotificationBadge.js";
|
|
67
|
+
import { MobileCardEntityRow as mt } from "./components/app/mobile-card/MobileCardEntityRow.js";
|
|
68
|
+
import { MobileCardSkeleton as ht, MobileCardSkeletonList as gt, SkeletonBlock as _t } from "./components/app/mobile-card/MobileCardSkeleton.js";
|
|
69
|
+
import { preset as vt } from "./preset.js";
|
|
70
|
+
import { createListCollection as yt, createToaster as bt, parseColor as xt, parseDate as St } from "@ark-ui/react";
|
|
71
|
+
import { formatPhoneNumber as Ct, formatPhoneNumberIntl as wt, getCountries as Tt, getCountryCallingCode as Et, isPossiblePhoneNumber as Dt, isSupportedCountry as Ot, isValidPhoneNumber as kt, parsePhoneNumber as At } from "react-phone-number-input";
|
|
72
|
+
export { e as Accordion, t as AccordionItem, n as AccordionItemContent, r as AccordionItemIndicator, i as AccordionItemTrigger, le as ActionCard, ue as ActionCardDescription, de as ActionCardTitle, fe as Alert, ct as AppNavigation, lt as AppNavigationLanguageSelect, He as Avatar, X as Box, Se as Breadcrumb, Ce as BreadcrumbItem, we as BreadcrumbLink, o as Button, Ne as ButtonFilter, Xe as Chat, Je as ChatDocumentMessage, qe as ChatMessage, Ye as ChatProfileAvatar, Ze as ChatScoreBreakdown, Qe as ChatTextInput, s as Checkbox, Le as CheckboxCard, c as CheckboxGroup, ae as Chip, oe as ChipAvatar, se as ChipClearTrigger, ce as ChipLabel, Be as Collapsible, Re as Combobox, $e as DEFAULT_SUPPLIER_RATING_LABELS, Z as DatePicker, Ve as Dialog, u as Drawer, d as DrawerBody, f as DrawerCloseTrigger, p as DrawerContent, m as DrawerContext, h as DrawerFooter, g as DrawerHeader, _ as DrawerTitle, v as DrawerTrigger, We as Flag, Ge as FlagCountryCodes, y as FormControl, S as FormHelperText, x as FormLabel, C as Heading, H as Highlight, U as HighlightedInput, ze as Icon, l as IconButton, Me as Illustration, V as Input, q as InputAddon, J as InputGroup, W as InputSlot, Ue as Menu, mt as MobileCardEntityRow, ft as MobileCardHeader, pt as MobileCardNotificationBadge, dt as MobileCardShell, ht as MobileCardSkeleton, gt as MobileCardSkeletonList, ut as MobileNavigation, Ke as OriginSelect, je as Pagination, Y as PhoneNumberInput, Te as Popover, Ee as PopoverAnchor, De as PopoverCloseTrigger, Oe as PopoverContent, ke as PopoverContext, Ae as PopoverTrigger, ot as PriceTag, st as ProductCardCatalog, $ as RadioButtonGroup, ee as RadioButtonGroupItem, te as RadioButtonGroupLabel, Ie as RadioCardGroup, ne as RadioGroup, re as RadioGroupItem, ie as RadioGroupLabel, G as Renderer, K as Root, et as SUPPLIER_RATING_MAX, z as Select, B as SelectLanguage, _t as SkeletonBlock, Pe as StatusTagSelect, M as Steps, N as StepsContent, P as StepsIndicator, F as StepsItem, I as StepsList, L as StepsSeparator, R as StepsTrigger, at as SupplierRatingBadge, tt as SupplierRatingBreakdown, w as Switch, Fe as SwitchCard, pe as Table, me as TableContainer, he as TableEmptyRow, ge as TableGroupTitle, D as Tabs, O as TabsChip, k as TabsContent, A as TabsList, j as TabsTrigger, Q as Tag, _e as Tbody, ve as Td, T as Text, E as Textarea, ye as Th, be as Thead, b as Tooltip, xe as Tr, yt as createListCollection, bt as createToaster, nt as formatOverall, Ct as formatPhoneNumber, wt as formatPhoneNumberIntl, rt as formatResponseDelay, Tt as getCountries, Et as getCountryCallingCode, it as getHeadlineColor, Dt as isPossiblePhoneNumber, Ot as isSupportedCountry, kt as isValidPhoneNumber, xt as parseColor, St as parseDate, At as parsePhoneNumber, vt as preset, a as useAccordion };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use client";let e=require("@ark-ui/react");var t=(0,require("@pandacss/dev").defineSlotRecipe)({base:{control:{fontFamily:`satoshi`,position:`relative`,'&:has(> [data-part="trigger"][hidden])':{'& > [data-part="clear-trigger"]':{right:`space-16!`}},_disabled:{cursor:`not-allowed`},'&[data-multiple="true"]':{display:`flex`,alignItems:`center`,flexWrap:`wrap`,gap:`space-4`,minHeight:`40px`,
|
|
1
|
+
"use client";let e=require("@ark-ui/react");var t=(0,require("@pandacss/dev").defineSlotRecipe)({base:{control:{fontFamily:`satoshi`,position:`relative`,'&:has(> [data-part="trigger"][hidden])':{'& > [data-part="clear-trigger"]':{right:`space-16!`}},_disabled:{cursor:`not-allowed`},'&[data-multiple="true"]':{display:`flex`,alignItems:`center`,flexWrap:`wrap`,gap:`space-4`,minHeight:`40px`,paddingTop:`space-8`,paddingBottom:`space-4`,paddingLeft:`space-8`,paddingRight:`space-48`,border:`1px solid {colors.grey.100}`,borderRadius:`radius-8`,cursor:`text`,transitionProperty:`border-color`,transitionDuration:`normal`,_focusWithin:{borderColor:`primary.500`}},'&[data-multiple="true"][data-open]':{borderColor:`primary.500`,borderBottomColor:`grey.100`,borderBottomLeftRadius:`radius-0`,borderBottomRightRadius:`radius-0`}},content:{fontFamily:`satoshi`,background:`background`,borderWidth:1,borderColor:`primary.500`,borderStyle:`solid`,borderTopStyle:`none`,borderBottomLeftRadius:`radius-8`,borderBottomRightRadius:`radius-8`,display:`flex`,flexDirection:`column`,outline:0,zIndex:`modal`,maxHeight:`180px`,overflow:`auto`},clearTrigger:{position:`absolute`,cursor:`pointer`,right:`space-48`,top:`10px`,color:`secondary.900`,_disabled:{color:`grey.300`,pointerEvents:`none`}},trigger:{position:`absolute`,cursor:`pointer`,right:`space-16`,top:`9px`,color:{base:`secondary.900`,_disabled:`grey.300`},_disabled:{_focus:{border:`none`},pointerEvents:`none`,userSelect:`none`,cursor:`not-allowed`}},item:{_disabled:{cursor:`not-allowed`},alignItems:`center`,background:{_disabled:{_hover:`grey.100!`,_selected:`grey.50!`,_checked:`grey.50!`,base:`grey.100!`},_selected:`primary.500`,_checked:`primary.500`,_highlighted:`primary.200`,_hover:`primary.200`,base:`background`},color:{_disabled:{_hover:`grey.300!`,_selected:`grey.300!`,_checked:`grey.300!`,base:`grey.300!`},_selected:`white`,_checked:`white`},cursor:`pointer`,display:`flex`,gap:`space-4`,transitionDuration:`fast`,transitionProperty:`background, color`,transitionTimingFunction:`default`,"& p":{color:`inherit!`}},itemGroupLabel:{textStyle:`body.sm`},root:{display:`flex`,flexDirection:`column`,gap:`space-4`,width:`full`,_disabled:{cursor:`not-allowed`}},input:{_disabled:{pointerEvents:`none`},_placeholderShown:{color:{base:`grey.400`,_disabled:`grey.300`}},_open:{border:`1px solid {colors.primary.500}`,_open:{borderBottomLeftRadius:`radius-0!`,borderBottomRightRadius:`radius-0!`}},alignItems:`center`,borderBottomColor:{_open:`grey.100`},paddingRight:{base:`space-60!`,'&[value]:not([value=""])':`90px!`},position:`relative`,'&[data-multiple="true"]':{border:`none!`,background:`transparent`,minHeight:`auto!`,height:`auto`,width:`auto!`,minWidth:`90px`,flex:`1 1 90px`,paddingBlock:`space-2!`,paddingLeft:`space-0!`,paddingRight:`space-0!`,_open:{border:`none!`}}}},className:`combobox`,defaultVariants:{size:`md`},jsx:[`Combobox`],slots:e.comboboxAnatomy.keys(),variants:{hideClearTrigger:{true:{input:{paddingRight:{base:`space-60!`,'&[value]:not([value=""])':`space-60!`}},clearTrigger:{display:`none`}}},size:{md:{item:{px:`space-16`,py:`space-8`,textStyle:`body.md`},input:{gap:`space-8`,minH:`40px`,minW:`size-16`,py:`space-8`,px:`space-16`,textStyle:`body.md`}}}}});exports.comboboxRecipe=t;
|
|
2
2
|
//# sourceMappingURL=combobox.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"combobox.cjs","names":[],"sources":["../../../src/theme/recipes/combobox.ts"],"sourcesContent":["import { comboboxAnatomy } from '@ark-ui/react'\nimport { defineSlotRecipe } from '@pandacss/dev'\n\nexport const comboboxRecipe = defineSlotRecipe({\n base: {\n control: {\n fontFamily: 'satoshi',\n position: 'relative',\n '&:has(> [data-part=\"trigger\"][hidden])': {\n '& > [data-part=\"clear-trigger\"]': {\n right: 'space-16!',\n },\n },\n _disabled: {\n cursor: 'not-allowed',\n },\n // Tags-input layout (multiple mode): the control becomes the bordered box\n // holding the selected chips + a borderless input. Styled via a self\n // attribute (`&[data-multiple]`) — panda drops ancestor-combinator nested\n // selectors from slot recipes, but keeps `&`-first ones. Ships via the\n // recipe (inline css() does not reach consumer apps).\n '&[data-multiple=\"true\"]': {\n display: 'flex',\n alignItems: 'center',\n flexWrap: 'wrap',\n gap: 'space-4',\n minHeight: '40px',\n
|
|
1
|
+
{"version":3,"file":"combobox.cjs","names":[],"sources":["../../../src/theme/recipes/combobox.ts"],"sourcesContent":["import { comboboxAnatomy } from '@ark-ui/react'\nimport { defineSlotRecipe } from '@pandacss/dev'\n\nexport const comboboxRecipe = defineSlotRecipe({\n base: {\n control: {\n fontFamily: 'satoshi',\n position: 'relative',\n '&:has(> [data-part=\"trigger\"][hidden])': {\n '& > [data-part=\"clear-trigger\"]': {\n right: 'space-16!',\n },\n },\n _disabled: {\n cursor: 'not-allowed',\n },\n // Tags-input layout (multiple mode): the control becomes the bordered box\n // holding the selected chips + a borderless input. Styled via a self\n // attribute (`&[data-multiple]`) — panda drops ancestor-combinator nested\n // selectors from slot recipes, but keeps `&`-first ones. Ships via the\n // recipe (inline css() does not reach consumer apps).\n '&[data-multiple=\"true\"]': {\n display: 'flex',\n alignItems: 'center',\n flexWrap: 'wrap',\n gap: 'space-4',\n minHeight: '40px',\n // Extra top padding clears the FormControl's floating label (absolute,\n // top:-8, white bg) so the first wrapped chip row isn't covered by it —\n // the single-line input's `py` does the same. Bottom stays tight.\n paddingTop: 'space-8',\n paddingBottom: 'space-4',\n paddingLeft: 'space-8',\n paddingRight: 'space-48',\n border: '1px solid {colors.grey.100}',\n borderRadius: 'radius-8',\n cursor: 'text',\n transitionProperty: 'border-color',\n transitionDuration: 'normal',\n _focusWithin: { borderColor: 'primary.500' },\n },\n // Flatten the bottom edge while the dropdown is open so it merges cleanly.\n '&[data-multiple=\"true\"][data-open]': {\n borderColor: 'primary.500',\n borderBottomColor: 'grey.100',\n borderBottomLeftRadius: 'radius-0',\n borderBottomRightRadius: 'radius-0',\n },\n },\n content: {\n fontFamily: 'satoshi',\n background: 'background',\n borderWidth: 1,\n borderColor: 'primary.500',\n borderStyle: 'solid',\n borderTopStyle: 'none',\n borderBottomLeftRadius: 'radius-8',\n borderBottomRightRadius: 'radius-8',\n display: 'flex',\n flexDirection: 'column',\n outline: 0,\n zIndex: 'modal',\n maxHeight: '180px',\n overflow: 'auto',\n },\n clearTrigger: {\n position: 'absolute',\n cursor: 'pointer',\n right: 'space-48',\n top: '10px',\n color: 'secondary.900',\n _disabled: {\n color: 'grey.300',\n pointerEvents: 'none',\n },\n },\n trigger: {\n position: 'absolute',\n cursor: 'pointer',\n right: 'space-16',\n top: '9px',\n color: {\n base: 'secondary.900',\n _disabled: 'grey.300',\n },\n _disabled: {\n _focus: {\n border: 'none',\n },\n pointerEvents: 'none',\n userSelect: 'none',\n cursor: 'not-allowed',\n },\n },\n item: {\n _disabled: {\n cursor: 'not-allowed',\n },\n alignItems: 'center',\n background: {\n _disabled: {\n _hover: 'grey.100!',\n _selected: 'grey.50!',\n _checked: 'grey.50!',\n base: 'grey.100!',\n },\n _selected: 'primary.500',\n _checked: 'primary.500',\n _highlighted: 'primary.200',\n _hover: 'primary.200',\n base: 'background',\n },\n color: {\n _disabled: {\n _hover: 'grey.300!',\n _selected: 'grey.300!',\n _checked: 'grey.300!',\n base: 'grey.300!',\n },\n _selected: 'white',\n _checked: 'white',\n },\n cursor: 'pointer',\n display: 'flex',\n gap: 'space-4',\n transitionDuration: 'fast',\n transitionProperty: 'background, color',\n transitionTimingFunction: 'default',\n '& p': {\n color: 'inherit!',\n },\n },\n itemGroupLabel: {\n textStyle: 'body.sm',\n },\n root: {\n display: 'flex',\n flexDirection: 'column',\n gap: 'space-4',\n width: 'full',\n _disabled: {\n cursor: 'not-allowed',\n },\n },\n input: {\n _disabled: {\n pointerEvents: 'none',\n },\n _placeholderShown: {\n color: {\n base: 'grey.400',\n _disabled: 'grey.300',\n },\n },\n _open: {\n border: '1px solid {colors.primary.500}',\n _open: {\n borderBottomLeftRadius: 'radius-0!',\n borderBottomRightRadius: 'radius-0!',\n },\n },\n alignItems: 'center',\n borderBottomColor: {\n _open: 'grey.100',\n },\n paddingRight: {\n base: 'space-60!',\n '&[value]:not([value=\"\"])': '90px!',\n },\n position: 'relative',\n // In tags-input (multiple) mode the input sits inline inside the control\n // box, so it must be borderless, auto-width and flush (! beats the base\n // important paddingRight and the _open border). Self-attribute selector so\n // panda keeps it (see the control slot note above).\n '&[data-multiple=\"true\"]': {\n border: 'none!',\n background: 'transparent',\n minHeight: 'auto!',\n height: 'auto',\n width: 'auto!',\n minWidth: '90px',\n flex: '1 1 90px',\n paddingBlock: 'space-2!',\n paddingLeft: 'space-0!',\n paddingRight: 'space-0!',\n _open: { border: 'none!' },\n },\n },\n },\n className: 'combobox',\n defaultVariants: {\n size: 'md',\n },\n jsx: ['Combobox'],\n slots: comboboxAnatomy.keys(),\n variants: {\n hideClearTrigger: {\n true: {\n input: {\n paddingRight: {\n base: 'space-60!',\n '&[value]:not([value=\"\"])': 'space-60!',\n },\n },\n clearTrigger: {\n display: 'none',\n },\n },\n },\n size: {\n md: {\n item: { px: 'space-16', py: 'space-8', textStyle: 'body.md' },\n input: {\n gap: 'space-8',\n minH: '40px',\n minW: 'size-16',\n py: 'space-8',\n px: 'space-16',\n textStyle: 'body.md',\n },\n },\n },\n },\n})\n"],"mappings":"4CAGA,IAAa,GAAA,yBAAA,EAAA,kBAAkC,CAC7C,KAAM,CACJ,QAAS,CACP,WAAY,UACZ,SAAU,WACV,yCAA0C,CACxC,kCAAmC,CACjC,MAAO,WACT,CACF,EACA,UAAW,CACT,OAAQ,aACV,EAMA,0BAA2B,CACzB,QAAS,OACT,WAAY,SACZ,SAAU,OACV,IAAK,UACL,UAAW,OAIX,WAAY,UACZ,cAAe,UACf,YAAa,UACb,aAAc,WACd,OAAQ,8BACR,aAAc,WACd,OAAQ,OACR,mBAAoB,eACpB,mBAAoB,SACpB,aAAc,CAAE,YAAa,aAAc,CAC7C,EAEA,qCAAsC,CACpC,YAAa,cACb,kBAAmB,WACnB,uBAAwB,WACxB,wBAAyB,UAC3B,CACF,EACA,QAAS,CACP,WAAY,UACZ,WAAY,aACZ,YAAa,EACb,YAAa,cACb,YAAa,QACb,eAAgB,OAChB,uBAAwB,WAC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