material-plus-ui 1.2.0 → 1.3.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.
Files changed (187) hide show
  1. package/README.md +21 -1
  2. package/dist/components/accordion/MPAccordion.js +1 -1
  3. package/dist/components/alert/MPAlert.js +1 -1
  4. package/dist/components/animate-appear/MPAnimateAppear.js +1 -1
  5. package/dist/components/animate-blink/MPAnimateBlink.js +1 -1
  6. package/dist/components/animate-fade/MPAnimateFade.js +1 -1
  7. package/dist/components/animate-grow/MPAnimateGrow.js +1 -1
  8. package/dist/components/animate-headline/MPAnimateHeadline.js +1 -1
  9. package/dist/components/animate-lighting/MPAnimateLighting.js +1 -1
  10. package/dist/components/animate-marquee/MPAnimateMarquee.js +1 -1
  11. package/dist/components/animate-rotate/MPAnimateRotate.js +1 -1
  12. package/dist/components/animate-slide/MPAnimateSlide.js +1 -1
  13. package/dist/components/animate-typing/MPAnimateTyping.js +1 -1
  14. package/dist/components/animate-zoom/MPAnimateZoom.js +1 -1
  15. package/dist/components/aspect-ratio/MPAspectRatio.js +1 -1
  16. package/dist/components/avatar/MPAvatar.js +1 -1
  17. package/dist/components/badge/MPBadge.js +1 -1
  18. package/dist/components/blockquote/MPBlockquote.js +1 -1
  19. package/dist/components/bottom-navigation/MPBottomNavigation.js +1 -1
  20. package/dist/components/box/MPBox.js +1 -1
  21. package/dist/components/breadcrumb/MPBreadcrumb.js +1 -1
  22. package/dist/components/button/MPButton.js +1 -1
  23. package/dist/components/button-group/MPButtonGroup.js +1 -1
  24. package/dist/components/card/MPCard.js +1 -1
  25. package/dist/components/carousel/MPCarousel.js +1 -1
  26. package/dist/components/chat-bubble/MPChatBubble.js +1 -1
  27. package/dist/components/checkbox/MPCheckbox.js +1 -1
  28. package/dist/components/chip/MPChip.js +1 -1
  29. package/dist/components/collapsible/MPCollapsible.js +1 -1
  30. package/dist/components/color-picker/MPColorPicker.js +1 -1
  31. package/dist/components/container/MPContainer.js +1 -1
  32. package/dist/components/date-picker/MPDatePicker.js +1 -1
  33. package/dist/components/date-range-picker/MPDateRangePicker.js +1 -1
  34. package/dist/components/date-time-picker/MPDateTimePicker.js +1 -1
  35. package/dist/components/divider/MPDivider.js +1 -1
  36. package/dist/components/empty/MPEmpty.js +1 -1
  37. package/dist/components/file-picker/MPFilePicker.js +1 -1
  38. package/dist/components/floating-action-button/MPFloatingActionButton.js +1 -1
  39. package/dist/components/grid/MPGrid.js +1 -1
  40. package/dist/components/highlight/MPHighlight.js +1 -1
  41. package/dist/components/icon/MPIcon.js +1 -1
  42. package/dist/components/icon-button/MPIconButton.js +1 -1
  43. package/dist/components/list/MPList.js +1 -1
  44. package/dist/components/otp-field/MPOtpField.js +1 -1
  45. package/dist/components/pagination/MPPagination.js +1 -1
  46. package/dist/components/panes/MPPanes.js +1 -1
  47. package/dist/components/pill/MPPill.js +1 -1
  48. package/dist/components/progress-box/MPProgressBox.js +1 -1
  49. package/dist/components/progress-circular/MPProgressCircular.js +1 -1
  50. package/dist/components/progress-linear/MPProgressLinear.js +1 -1
  51. package/dist/components/radio-group/MPRadioGroup.js +1 -1
  52. package/dist/components/rating/MPRating.js +1 -1
  53. package/dist/components/segmented-button/MPSegmentedButton.js +1 -1
  54. package/dist/components/select/MPSelect.js +1 -1
  55. package/dist/components/shortcut/MPShortcut.js +1 -1
  56. package/dist/components/skeleton/MPSkeleton.js +1 -1
  57. package/dist/components/slider/MPSlider.js +1 -1
  58. package/dist/components/spoiler/MPSpoiler.js +1 -1
  59. package/dist/components/switch/MPSwitch.js +1 -1
  60. package/dist/components/tabs/MPTabs.js +1 -1
  61. package/dist/components/text-field/MPTextField.js +1 -1
  62. package/dist/components/text-link/MPTextLink.js +1 -1
  63. package/dist/components/time-picker/MPTimePicker.js +1 -1
  64. package/dist/components/timeline/MPTimeline.js +1 -1
  65. package/dist/components/typography/MPTypography.js +1 -1
  66. package/dist/index.d.ts +1 -0
  67. package/dist/index.js +1 -1
  68. package/dist/internal/button-group.js +1 -1
  69. package/dist/internal/i18n.d.ts +64 -3
  70. package/dist/internal/i18n.js +1 -1
  71. package/dist/internal/locale.js +1 -1
  72. package/dist/internal/menu.js +1 -1
  73. package/dist/locales/ar.d.ts +17 -0
  74. package/dist/locales/ar.js +1 -0
  75. package/dist/locales/de.d.ts +17 -0
  76. package/dist/locales/de.js +1 -0
  77. package/dist/locales/es.d.ts +17 -0
  78. package/dist/locales/es.js +1 -0
  79. package/dist/locales/fr.d.ts +17 -0
  80. package/dist/locales/fr.js +1 -0
  81. package/dist/locales/hi.d.ts +17 -0
  82. package/dist/locales/hi.js +1 -0
  83. package/dist/locales/id.d.ts +17 -0
  84. package/dist/locales/id.js +1 -0
  85. package/dist/locales/index.d.ts +89 -0
  86. package/dist/locales/index.js +1 -0
  87. package/dist/locales/it.d.ts +17 -0
  88. package/dist/locales/it.js +1 -0
  89. package/dist/locales/ja.d.ts +17 -0
  90. package/dist/locales/ja.js +1 -0
  91. package/dist/locales/ko.d.ts +17 -0
  92. package/dist/locales/ko.js +1 -0
  93. package/dist/locales/nl.d.ts +17 -0
  94. package/dist/locales/nl.js +1 -0
  95. package/dist/locales/pl.d.ts +17 -0
  96. package/dist/locales/pl.js +1 -0
  97. package/dist/locales/pt.d.ts +17 -0
  98. package/dist/locales/pt.js +1 -0
  99. package/dist/locales/ru.d.ts +17 -0
  100. package/dist/locales/ru.js +1 -0
  101. package/dist/locales/th.d.ts +17 -0
  102. package/dist/locales/th.js +1 -0
  103. package/dist/locales/tr.d.ts +17 -0
  104. package/dist/locales/tr.js +1 -0
  105. package/dist/locales/vi.d.ts +17 -0
  106. package/dist/locales/vi.js +1 -0
  107. package/dist/locales/zh-hans.d.ts +21 -0
  108. package/dist/locales/zh-hans.js +1 -0
  109. package/dist/locales/zh-hant.d.ts +20 -0
  110. package/dist/locales/zh-hant.js +1 -0
  111. package/dist/styles/accordion.css +2 -0
  112. package/dist/styles/alert.css +2 -0
  113. package/dist/styles/animate-appear.css +2 -0
  114. package/dist/styles/animate-blink.css +2 -0
  115. package/dist/styles/animate-fade.css +2 -0
  116. package/dist/styles/animate-grow.css +2 -0
  117. package/dist/styles/animate-headline.css +2 -0
  118. package/dist/styles/animate-lighting.css +2 -0
  119. package/dist/styles/animate-marquee.css +2 -0
  120. package/dist/styles/animate-rotate.css +2 -0
  121. package/dist/styles/animate-slide.css +2 -0
  122. package/dist/styles/animate-typing.css +2 -0
  123. package/dist/styles/animate-zoom.css +2 -0
  124. package/dist/styles/aspect-ratio.css +2 -0
  125. package/dist/styles/avatar.css +2 -0
  126. package/dist/styles/badge.css +2 -0
  127. package/dist/styles/blockquote.css +2 -0
  128. package/dist/styles/bottom-navigation.css +2 -0
  129. package/dist/styles/box.css +2 -0
  130. package/dist/styles/breadcrumb.css +2 -0
  131. package/dist/styles/button-group.css +2 -0
  132. package/dist/styles/button.css +2 -0
  133. package/dist/styles/card.css +2 -0
  134. package/dist/styles/carousel.css +2 -0
  135. package/dist/styles/chat-bubble.css +2 -0
  136. package/dist/styles/checkbox.css +2 -0
  137. package/dist/styles/chip.css +2 -0
  138. package/dist/styles/collapsible.css +2 -0
  139. package/dist/styles/color-picker.css +2 -0
  140. package/dist/styles/combobox.css +2 -0
  141. package/dist/styles/container.css +2 -0
  142. package/dist/styles/date-picker.css +2 -0
  143. package/dist/styles/date-range-picker.css +2 -0
  144. package/dist/styles/date-time-picker.css +2 -0
  145. package/dist/styles/dialog.css +2 -0
  146. package/dist/styles/divider.css +2 -0
  147. package/dist/styles/drawer.css +2 -0
  148. package/dist/styles/empty.css +2 -0
  149. package/dist/styles/file-picker.css +2 -0
  150. package/dist/styles/floating-action-button.css +2 -0
  151. package/dist/styles/grid.css +2 -0
  152. package/dist/styles/highlight.css +2 -0
  153. package/dist/styles/icon-button.css +2 -0
  154. package/dist/styles/icon.css +2 -0
  155. package/dist/styles/list.css +2 -0
  156. package/dist/styles/locale.css +2 -0
  157. package/dist/styles/menu.css +2 -0
  158. package/dist/styles/number-field.css +2 -0
  159. package/dist/styles/otp-field.css +2 -0
  160. package/dist/styles/overlay.css +2 -0
  161. package/dist/styles/pagination.css +2 -0
  162. package/dist/styles/panes.css +2 -0
  163. package/dist/styles/pill.css +2 -0
  164. package/dist/styles/popover.css +2 -0
  165. package/dist/styles/progress-box.css +2 -0
  166. package/dist/styles/progress-circular.css +2 -0
  167. package/dist/styles/progress-linear.css +2 -0
  168. package/dist/styles/radio-group.css +2 -0
  169. package/dist/styles/rating.css +2 -0
  170. package/dist/styles/segmented-button.css +2 -0
  171. package/dist/styles/select.css +2 -0
  172. package/dist/styles/shortcut.css +2 -0
  173. package/dist/styles/skeleton.css +2 -0
  174. package/dist/styles/slider.css +2 -0
  175. package/dist/styles/snackbar.css +2 -0
  176. package/dist/styles/spoiler.css +2 -0
  177. package/dist/styles/switch.css +2 -0
  178. package/dist/styles/table.css +2 -0
  179. package/dist/styles/tabs.css +2 -0
  180. package/dist/styles/text-field.css +2 -0
  181. package/dist/styles/text-link.css +2 -0
  182. package/dist/styles/time-picker.css +2 -0
  183. package/dist/styles/timeline.css +2 -0
  184. package/dist/styles/tokens.css +2 -0
  185. package/dist/styles/tooltip.css +2 -0
  186. package/dist/styles/typography.css +2 -0
  187. package/package.json +22 -3
@@ -1 +1 @@
1
- import{jsx as e,jsxs as t}from"react/jsx-runtime";import*as o from"react";import{Field as n}from"@base-ui/react/field";import{MPIcon as a}from"../icon/MPIcon";import{MPFieldLabel as r,MPFieldOutline as l,useFloatingLabel as i}from"../../internal/FieldOutline";import{VisibilityIcon as s,VisibilityOffIcon as d}from"../../constants/icons";import{useMPLocale as p,useMPMessages as c}from"../../internal/locale";const u={xs:{padding:"px-2",control:"py-1.5",text:"text-mp-body-medium",icon:16},sm:{padding:"px-3",control:"py-2.5",text:"text-mp-body-medium",icon:18},md:{padding:"px-4",control:"py-4",text:"text-mp-body-large",icon:20},lg:{padding:"px-4",control:"py-5",text:"text-mp-body-large",icon:22},xl:{padding:"px-5",control:"py-6",text:"text-mp-body-large",icon:24}};export const MPTextField=o.forwardRef(function({value:m,name:f,type:x="text",placeholder:b,autoComplete:g,label:y,floatingLabel:h=!0,onChange:v,onFormReset:w,onSubmit:C,errorMessage:k="",required:j=!1,fullWidth:z=!1,readOnly:E=!1,autoFocus:F=!1,size:M="md",disabled:N=!1,disableEnterKey:P=!1,rows:S,maxLength:q,startIcon:D,resizable:L=!1,id:R,locale:I,passwordLabels:O},B){const K=p(I),U=c("textField",K,O),_=o.useRef(null),[T,W]=o.useState(!1),[$,A]=o.useState(!1),[G,H]=o.useState(m),J=o.useId(),Q=R??J,V=!!S,X=k.length>0,Y=u[M],Z=$?G:m,{shrunk:ee,focusProps:te}=i({floating:h&&!!y,filled:Z.length>0,pinned:!!D}),oe=o.useCallback(e=>{_.current=e,"function"==typeof B?B(e):B&&(B.current=e)},[B]),ne=e=>{e.preventDefault()};return o.useEffect(()=>{$||H(m)},[m,$]),o.useEffect(()=>{F&&!window.matchMedia("(max-width: 599.95px)").matches&&_.current?.focus()},[]),t(n.Root,{className:["mp-text-field group relative",z?"w-full":"inline-block","align-top"].join(" "),disabled:N,invalid:X,"data-mp-size":M,...te,children:[t("div",{className:["relative flex w-full items-center gap-2",Y.padding,V?"py-2":""].filter(Boolean).join(" "),children:[e(l,{label:y,required:j,notched:ee}),D?e("span",{className:"text-mp-on-surface-variant group-data-disabled:text-mp-on-surface/38 flex shrink-0 items-center",children:D}):null,e(n.Control,{render:V?e("textarea",{rows:S}):e("input",{}),id:Q,name:f,type:V?void 0:T?"text":x,required:j,readOnly:E,disabled:N,autoComplete:g,placeholder:ee?b:void 0,maxLength:q,value:Z,ref:oe,className:[`${Y.text} text-mp-on-surface w-full min-w-0 flex-1`,"font-[family-name:var(--mp-sys-typescale-body-large-font)]","appearance-none border-0 bg-transparent px-0 outline-none","caret-mp-primary",Y.control,V?"py-0":"",V&&L?"resize-y":"resize-none","group-data-disabled:text-mp-on-surface/38","placeholder:text-mp-on-surface-variant group-data-disabled:placeholder:text-mp-on-surface/38"].filter(Boolean).join(" "),onChange:e=>{w?.();const t=e.target.value;$&&H(t),v?.(t)},onCompositionStart:()=>{A(!0),H(m)},onCompositionUpdate:e=>{H(e.target.value)},onCompositionEnd:e=>{A(!1);const t=e.target.value;w?.(),v?.(t),H(t)},onKeyDown:e=>{if("Enter"===e.key){if(function(e){const t=e.nativeEvent;return t.isComposing||229===t.keyCode}(e))return;C?.(),V&&!P||e.preventDefault()}}}),"password"!==x||V?null:e("button",{type:"button","aria-label":T?U.hidePassword:U.showPassword,onClick:()=>W(e=>!e),onMouseDown:ne,onMouseUp:ne,disabled:N,className:["text-mp-on-surface-variant -mr-1 flex shrink-0 items-center justify-center","cursor-pointer appearance-none border-0 bg-transparent p-1 font-[inherit]","rounded-full outline-none","hover:text-mp-on-surface focus-visible:text-mp-primary","disabled:text-mp-on-surface/38 disabled:cursor-default"].join(" "),children:e(a,{icon:T?s:d,size:Y.icon})}),y?e(r,{size:M,label:y,required:j,htmlFor:Q,shrunk:ee,multiline:V}):null]}),X?e(n.Error,{match:!0,className:["mp-text-field__support text-mp-body-small text-mp-error mt-1 block",Y.padding,"group-data-disabled:text-mp-on-surface/38"].join(" "),children:k}):null]})});
1
+ import{jsx as e,jsxs as t}from"react/jsx-runtime";import*as o from"react";import{Field as n}from"@base-ui/react/field";import{MPIcon as a}from"../icon/MPIcon";import{MPFieldLabel as r,MPFieldOutline as l,useFloatingLabel as i}from"../../internal/FieldOutline";import{VisibilityIcon as s,VisibilityOffIcon as d}from"../../constants/icons";import{useMPLocale as p,useMPMessages as c}from"../../internal/locale";const u={xs:{padding:"px-2",control:"py-1.5",text:"text-mp-body-medium",icon:16},sm:{padding:"px-3",control:"py-2.5",text:"text-mp-body-medium",icon:18},md:{padding:"px-4",control:"py-4",text:"text-mp-body-large",icon:20},lg:{padding:"px-4",control:"py-5",text:"text-mp-body-large",icon:22},xl:{padding:"px-5",control:"py-6",text:"text-mp-body-large",icon:24}};export const MPTextField=/*@__PURE__*/o.forwardRef(function({value:m,name:f,type:x="text",placeholder:b,autoComplete:g,label:y,floatingLabel:h=!0,onChange:v,onFormReset:w,onSubmit:C,errorMessage:k="",required:j=!1,fullWidth:z=!1,readOnly:E=!1,autoFocus:F=!1,size:M="md",disabled:N=!1,disableEnterKey:P=!1,rows:S,maxLength:q,startIcon:D,resizable:L=!1,id:R,locale:I,passwordLabels:O},B){const K=p(I),U=c("textField",K,O),_=o.useRef(null),[T,W]=o.useState(!1),[$,A]=o.useState(!1),[G,H]=o.useState(m),J=o.useId(),Q=R??J,V=!!S,X=k.length>0,Y=u[M],Z=$?G:m,{shrunk:ee,focusProps:te}=i({floating:h&&!!y,filled:Z.length>0,pinned:!!D}),oe=o.useCallback(e=>{_.current=e,"function"==typeof B?B(e):B&&(B.current=e)},[B]),ne=e=>{e.preventDefault()};return o.useEffect(()=>{$||H(m)},[m,$]),o.useEffect(()=>{F&&!window.matchMedia("(max-width: 599.95px)").matches&&_.current?.focus()},[]),t(n.Root,{className:["mp-text-field group relative",z?"w-full":"inline-block","align-top"].join(" "),disabled:N,invalid:X,"data-mp-size":M,...te,children:[t("div",{className:["relative flex w-full items-center gap-2",Y.padding,V?"py-2":""].filter(Boolean).join(" "),children:[e(l,{label:y,required:j,notched:ee}),D?e("span",{className:"text-mp-on-surface-variant group-data-disabled:text-mp-on-surface/38 flex shrink-0 items-center",children:D}):null,e(n.Control,{render:V?e("textarea",{rows:S}):e("input",{}),id:Q,name:f,type:V?void 0:T?"text":x,required:j,readOnly:E,disabled:N,autoComplete:g,placeholder:ee?b:void 0,maxLength:q,value:Z,ref:oe,className:[`${Y.text} text-mp-on-surface w-full min-w-0 flex-1`,"font-[family-name:var(--mp-sys-typescale-body-large-font)]","appearance-none border-0 bg-transparent px-0 outline-none","caret-mp-primary",Y.control,V?"py-0":"",V&&L?"resize-y":"resize-none","group-data-disabled:text-mp-on-surface/38","placeholder:text-mp-on-surface-variant group-data-disabled:placeholder:text-mp-on-surface/38"].filter(Boolean).join(" "),onChange:e=>{w?.();const t=e.target.value;$&&H(t),v?.(t)},onCompositionStart:()=>{A(!0),H(m)},onCompositionUpdate:e=>{H(e.target.value)},onCompositionEnd:e=>{A(!1);const t=e.target.value;w?.(),v?.(t),H(t)},onKeyDown:e=>{if("Enter"===e.key){if(function(e){const t=e.nativeEvent;return t.isComposing||229===t.keyCode}(e))return;C?.(),V&&!P||e.preventDefault()}}}),"password"!==x||V?null:e("button",{type:"button","aria-label":T?U.hidePassword:U.showPassword,onClick:()=>W(e=>!e),onMouseDown:ne,onMouseUp:ne,disabled:N,className:["text-mp-on-surface-variant -mr-1 flex shrink-0 items-center justify-center","cursor-pointer appearance-none border-0 bg-transparent p-1 font-[inherit]","rounded-full outline-none","hover:text-mp-on-surface focus-visible:text-mp-primary","disabled:text-mp-on-surface/38 disabled:cursor-default"].join(" "),children:e(a,{icon:T?s:d,size:Y.icon})}),y?e(r,{size:M,label:y,required:j,htmlFor:Q,shrunk:ee,multiline:V}):null]}),X?e(n.Error,{match:!0,className:["mp-text-field__support text-mp-body-small text-mp-error mt-1 block",Y.padding,"group-data-disabled:text-mp-on-surface/38"].join(" "),children:k}):null]})});
@@ -1 +1 @@
1
- import{jsx as e,Fragment as n,jsxs as o}from"react/jsx-runtime";import*as r from"react";import{useRender as i}from"@base-ui/react/use-render";import{MPIcon as t}from"../icon/MPIcon";import{ExternalLinkIcon as l,LinkIcon as s}from"../../constants/icons";import{accentSlots as a}from"../../internal/accent";import{PROSE_TEXT as c}from"../../internal/scale";import{VISUALLY_HIDDEN as m}from"../../internal/visually-hidden";const p={always:"[&.mp-link]:underline",hover:"[&.mp-link]:no-underline [&.mp-link]:hover:underline",none:"[&.mp-link]:no-underline"},d=["[&.mp-link]:[text-underline-offset:0.2em]","[&.mp-link]:[text-decoration-thickness:0.08em]","[&.mp-link]:[text-decoration-color:color-mix(in_oklab,currentColor_45%,transparent)]","[&.mp-link]:hover:[text-decoration-color:currentColor]"].join(" ");export const MPTextLink=r.forwardRef(function({href:r,underline:u="always",color:f,size:k,newTab:h=!1,icon:x,newTabLabel:b="Opens in a new tab",render:v,className:y,style:w,children:j,..._},g){const N=h?"_blank":_.target,T="_blank"===N,z=x??T,C=!0===z?e(t,{icon:T?l:s,size:"0.95em"}):z,L=["mp-link cursor-pointer","transition-[color,text-decoration-color]","duration-(--mp-sys-motion-duration-short4)","outline-mp-secondary focus-visible:outline-2 focus-visible:outline-offset-2","focus-visible:outline-solid focus-visible:rounded-mp-xs outline-none",k?c[k]:"",p[u],d,f?"[&.mp-link]:text-(--_mp-accent)":"[&.mp-link]:text-inherit",y??""].filter(Boolean).join(" ");return i({render:v??e("a",{}),ref:g,props:{href:r,target:N,rel:T?"noopener noreferrer":void 0,className:L,style:f?{...a(f),...w}:w,children:o(n,{children:[j,C?e("span",{className:"ms-[0.25em] inline-flex align-baseline",children:C}):null,T?o(n,{children:[" ",e("span",{className:m,children:b})]}):null]}),..._}})});
1
+ import{jsx as e,Fragment as n,jsxs as o}from"react/jsx-runtime";import*as r from"react";import{useRender as i}from"@base-ui/react/use-render";import{MPIcon as t}from"../icon/MPIcon";import{ExternalLinkIcon as l,LinkIcon as s}from"../../constants/icons";import{accentSlots as a}from"../../internal/accent";import{PROSE_TEXT as c}from"../../internal/scale";import{VISUALLY_HIDDEN as m}from"../../internal/visually-hidden";const p={always:"[&.mp-link]:underline",hover:"[&.mp-link]:no-underline [&.mp-link]:hover:underline",none:"[&.mp-link]:no-underline"},d=["[&.mp-link]:[text-underline-offset:0.2em]","[&.mp-link]:[text-decoration-thickness:0.08em]","[&.mp-link]:[text-decoration-color:color-mix(in_oklab,currentColor_45%,transparent)]","[&.mp-link]:hover:[text-decoration-color:currentColor]"].join(" ");export const MPTextLink=/*@__PURE__*/r.forwardRef(function({href:r,underline:u="always",color:f,size:k,newTab:h=!1,icon:x,newTabLabel:b="Opens in a new tab",render:v,className:y,style:w,children:j,..._},g){const N=h?"_blank":_.target,T="_blank"===N,z=x??T,C=!0===z?e(t,{icon:T?l:s,size:"0.95em"}):z,L=["mp-link cursor-pointer","transition-[color,text-decoration-color]","duration-(--mp-sys-motion-duration-short4)","outline-mp-secondary focus-visible:outline-2 focus-visible:outline-offset-2","focus-visible:outline-solid focus-visible:rounded-mp-xs outline-none",k?c[k]:"",p[u],d,f?"[&.mp-link]:text-(--_mp-accent)":"[&.mp-link]:text-inherit",y??""].filter(Boolean).join(" ");return i({render:v??e("a",{}),ref:g,props:{href:r,target:N,rel:T?"noopener noreferrer":void 0,className:L,style:f?{...a(f),...w}:w,children:o(n,{children:[j,C?e("span",{className:"ms-[0.25em] inline-flex align-baseline",children:C}):null,T?o(n,{children:[" ",e("span",{className:m,children:b})]}):null]}),..._}})});
@@ -1 +1 @@
1
- import{jsx as e,jsxs as o}from"react/jsx-runtime";import*as n from"react";import{MPButton as l}from"../button/MPButton";import{MPIcon as r}from"../icon/MPIcon";import{ClockIcon as t}from"../../constants/icons";import{MPTimeGrid as a}from"../../internal/Calendar";import{FOOTER_SIZE as i,MPPickerFooter as s,MPPickerShell as c,useDisplaySamples as u}from"../../internal/Picker";import{useMPLocale as d,useMPMessages as m}from"../../internal/locale";import{CONTROL_ICON as p}from"../../internal/scale";import{formatDate as h,isHour12 as f,isValidDate as g,secondsOfDay as S,timeUnitSpan as b,toISOTime as v,withPlaceholder as C,withTime as x}from"../../internal/date";export const MPTimePicker=n.forwardRef(function({value:k,defaultValue:w,onValueChange:z,open:D,defaultOpen:O,onOpenChange:y,referenceDate:P,minTime:T,maxTime:M,shouldDisableTime:j,hour12:I,showSeconds:V=!1,hourStep:B=1,minuteStep:N=1,secondStep:R=1,locale:F,format:H,placeholder:q,clearable:A=!1,showNowButton:E=!0,closeOnSelect:G=!1,labels:J,name:K,size:L="md",color:Q="primary",readOnly:U=!1,disabled:W=!1,startIcon:X,...Y},Z){const $=d(F),_=m("picker",$,J),ee=I??f($),[oe,ne]=n.useState(w??null),le=void 0!==k?k:oe,[re,te]=n.useState(O??!1),ae=D??re,[ie]=n.useState(()=>P??new Date),se=e=>{e&&(U||W)||(void 0===D&&te(e),y?.(e))},ce=e=>{void 0===k&&ne(e),z?.(e)},ue=n.useCallback((e,o)=>{const[n,l]=b(o,e);return!!(g(T)&&l<S(T))||(!!(g(M)&&n>S(M))||(j?.(e,o)??!1))},[T,M,j]),de=H??{hour:"numeric",minute:"2-digit",hour12:ee,...V?{second:"2-digit"}:{}},me=new Date,pe=x(P??ie,{hours:me.getHours(),minutes:me.getMinutes(),seconds:V?me.getSeconds():0}),he=E||A||!G,fe=C(u($,de),q);return e(c,{...Y,slug:"time-picker",size:L,color:Q,readOnly:U,disabled:W,triggerRef:Z,startIcon:void 0===X?e(r,{icon:t,size:p[L]}):X,display:g(le)?h(le,$,de):q??"",samples:fe,empty:!g(le),clearable:A,onClear:()=>ce(null),open:ae,onOpenChange:se,labels:_,hiddenValues:K?[{name:K,value:g(le)?v(le,V):""}]:void 0,children:o("div",{className:"flex flex-col "+(he?"gap-1.5":""),children:[e(a,{size:L,locale:$,value:g(le)?le:null,referenceDate:P??ie,onChange:e=>{ce(e),G&&se(!1)},hour12:ee,showSeconds:V,hourStep:B,minuteStep:N,secondStep:R,shouldDisableTime:ue,labels:_,autoFocus:!0}),he?o(s,{children:[A?e(l,{variant:"text",size:i[L],color:Q,onClick:()=>{ce(null),se(!1)},children:_.clear}):null,E?e(l,{variant:"text",size:i[L],color:Q,disabled:ue(pe,"second"),onClick:()=>{ce(pe),se(!1)},children:_.now}):null,G?null:e(l,{variant:"filled",size:i[L],color:Q,onClick:()=>se(!1),children:_.done})]}):null]})})});
1
+ import{jsx as e,jsxs as o}from"react/jsx-runtime";import*as n from"react";import{MPButton as l}from"../button/MPButton";import{MPIcon as r}from"../icon/MPIcon";import{ClockIcon as t}from"../../constants/icons";import{MPTimeGrid as a}from"../../internal/Calendar";import{FOOTER_SIZE as i,MPPickerFooter as s,MPPickerShell as c,useDisplaySamples as u}from"../../internal/Picker";import{useMPLocale as d,useMPMessages as m}from"../../internal/locale";import{CONTROL_ICON as p}from"../../internal/scale";import{formatDate as h,isHour12 as f,isValidDate as g,secondsOfDay as S,timeUnitSpan as b,toISOTime as v,withPlaceholder as C,withTime as x}from"../../internal/date";export const MPTimePicker=/*@__PURE__*/n.forwardRef(function({value:k,defaultValue:w,onValueChange:z,open:D,defaultOpen:O,onOpenChange:y,referenceDate:P,minTime:T,maxTime:M,shouldDisableTime:j,hour12:I,showSeconds:V=!1,hourStep:B=1,minuteStep:N=1,secondStep:R=1,locale:F,format:H,placeholder:q,clearable:A=!1,showNowButton:E=!0,closeOnSelect:G=!1,labels:J,name:K,size:L="md",color:Q="primary",readOnly:U=!1,disabled:W=!1,startIcon:X,...Y},Z){const $=d(F),_=m("picker",$,J),ee=I??f($),[oe,ne]=n.useState(w??null),le=void 0!==k?k:oe,[re,te]=n.useState(O??!1),ae=D??re,[ie]=n.useState(()=>P??new Date),se=e=>{e&&(U||W)||(void 0===D&&te(e),y?.(e))},ce=e=>{void 0===k&&ne(e),z?.(e)},ue=n.useCallback((e,o)=>{const[n,l]=b(o,e);return!!(g(T)&&l<S(T))||(!!(g(M)&&n>S(M))||(j?.(e,o)??!1))},[T,M,j]),de=H??{hour:"numeric",minute:"2-digit",hour12:ee,...V?{second:"2-digit"}:{}},me=new Date,pe=x(P??ie,{hours:me.getHours(),minutes:me.getMinutes(),seconds:V?me.getSeconds():0}),he=E||A||!G,fe=C(u($,de),q);return e(c,{...Y,slug:"time-picker",size:L,color:Q,readOnly:U,disabled:W,triggerRef:Z,startIcon:void 0===X?e(r,{icon:t,size:p[L]}):X,display:g(le)?h(le,$,de):q??"",samples:fe,empty:!g(le),clearable:A,onClear:()=>ce(null),open:ae,onOpenChange:se,labels:_,hiddenValues:K?[{name:K,value:g(le)?v(le,V):""}]:void 0,children:o("div",{className:"flex flex-col "+(he?"gap-1.5":""),children:[e(a,{size:L,locale:$,value:g(le)?le:null,referenceDate:P??ie,onChange:e=>{ce(e),G&&se(!1)},hour12:ee,showSeconds:V,hourStep:B,minuteStep:N,secondStep:R,shouldDisableTime:ue,labels:_,autoFocus:!0}),he?o(s,{children:[A?e(l,{variant:"text",size:i[L],color:Q,onClick:()=>{ce(null),se(!1)},children:_.clear}):null,E?e(l,{variant:"text",size:i[L],color:Q,disabled:ue(pe,"second"),onClick:()=>{ce(pe),se(!1)},children:_.now}):null,G?null:e(l,{variant:"filled",size:i[L],color:Q,onClick:()=>se(!1),children:_.done})]}):null]})})});
@@ -1 +1 @@
1
- import{jsx as e,jsxs as r}from"react/jsx-runtime";import*as t from"react";import{useRender as n}from"@base-ui/react/use-render";import{accentSlots as l}from"../../internal/accent";import{hasContent as a,META_TEXT as o,PROSE_TEXT as i,SHEET_TITLE as s}from"../../internal/scale";const c=t.createContext(null),m=t.createContext({index:0,last:!1}),p={xs:"0.875rem",sm:"1rem",md:"1.25rem",lg:"1.5rem",xl:"1.875rem"},d={xs:"gap-2",sm:"gap-2.5",md:"gap-3",lg:"gap-3.5",xl:"gap-4"},u={xs:"pb-5",sm:"pb-6",md:"pb-7",lg:"pb-8",xl:"pb-10"},x={xs:"pe-5",sm:"pe-6",md:"pe-7",lg:"pe-8",xl:"pe-10"},f={solid:"border-solid",dashed:"border-dashed",dotted:"border-dotted",none:""},b={complete:"bg-(--_mp-accent) text-(--_mp-on-accent)",current:"bg-(--_mp-accent) text-(--_mp-on-accent) shadow-[0_0_0_0.25rem_var(--_mp-accent-container)]",upcoming:"border-mp-outline text-mp-on-surface-variant border-2 bg-transparent"},v={complete:"border-(--_mp-accent)",current:"border-mp-outline-variant",upcoming:"border-mp-outline-variant"},h={complete:"text-mp-on-surface",current:"text-(--_mp-accent)",upcoming:"text-mp-on-surface-variant"};export const MPTimelineItem=t.forwardRef(function({title:n,meta:g,bullet:_,status:N,color:y,connector:z="solid",className:j,style:w,children:$,...C},M){const P=t.useContext(c),{index:B,last:k}=t.useContext(m),A=P?.size??"md",R=P?.orientation??"vertical",T=y??P?.color??"primary",I=P?.active??null,q=N??(null===I?"upcoming":B<I?"complete":B===I?"current":"upcoming"),D="horizontal"===R,E="none"!==z&&!k,F=e("span",{"aria-hidden":"true",className:["rounded-mp-full relative z-10 flex shrink-0 items-center justify-center","size-(--_mp-bullet) text-[calc(var(--_mp-bullet)*0.5)] leading-none font-medium","tabular-nums [&>svg]:size-[0.6em]",b[q],"transition-[background-color,border-color,box-shadow,color]","duration-(--mp-sys-motion-duration-short4)"].join(" "),children:_}),G=E?e("span",{"aria-hidden":"true",className:["pointer-events-none absolute",D?"start-(--_mp-bullet) top-[calc(var(--_mp-bullet)/2_-_1px)] end-0 border-t-2":"top-(--_mp-bullet) start-[calc(var(--_mp-bullet)/2_-_1px)] bottom-0 border-s-2",f[z],v[q]].filter(Boolean).join(" ")}):null,H=r("div",{className:"flex min-w-0 flex-col gap-0.5 "+(D?"mt-2":""),children:[a(n)||a(g)?r("div",{className:"flex flex-wrap items-baseline gap-x-2",children:[a(n)?e("span",{className:`${s[A]} ${h[q]}`,children:n}):null,a(g)?e("span",{className:`text-mp-on-surface-variant ${o}`,children:g}):null]}):null,a($)?e("div",{className:`text-mp-on-surface-variant ${i[A]}`,children:$}):null]});return r("li",{ref:M,"aria-current":"current"===q?"step":void 0,"data-status":q,className:["relative",D?`flex min-w-0 flex-1 flex-col ${k?"":x[A]}`:`flex ${d[A]} ${k?"":u[A]}`,j??""].filter(Boolean).join(" "),style:{"--_mp-bullet":p[A],...l(T),...w},...C,children:[G,F,H]})});export const MPTimeline=t.forwardRef(function({active:r,size:l="md",color:a="primary",orientation:o="vertical",render:i,className:s,style:p,children:d,...u},x){const f=t.Children.toArray(d),b=f.length,v=t.useMemo(()=>({size:l,orientation:o,color:a,active:r??null}),[l,o,a,r]),h=t.useMemo(()=>Array.from({length:b},(e,r)=>({index:r,last:r===b-1})),[b]),g=n({render:i??e("ol",{}),ref:x,props:{role:"list","data-mp-size":l,className:["mp-timeline flex","horizontal"===o?"flex-row":"flex-col",s??""].filter(Boolean).join(" "),style:p,children:f.map((r,t)=>e(m.Provider,{value:h[t],children:r},t)),...u}});return e(c.Provider,{value:v,children:g})});
1
+ import{jsx as e,jsxs as r}from"react/jsx-runtime";import*as t from"react";import{useRender as n}from"@base-ui/react/use-render";import{accentSlots as l}from"../../internal/accent";import{hasContent as a,META_TEXT as o,PROSE_TEXT as i,SHEET_TITLE as s}from"../../internal/scale";const c=/*@__PURE__*/t.createContext(null),m=/*@__PURE__*/t.createContext({index:0,last:!1}),p={xs:"0.875rem",sm:"1rem",md:"1.25rem",lg:"1.5rem",xl:"1.875rem"},d={xs:"gap-2",sm:"gap-2.5",md:"gap-3",lg:"gap-3.5",xl:"gap-4"},u={xs:"pb-5",sm:"pb-6",md:"pb-7",lg:"pb-8",xl:"pb-10"},x={xs:"pe-5",sm:"pe-6",md:"pe-7",lg:"pe-8",xl:"pe-10"},f={solid:"border-solid",dashed:"border-dashed",dotted:"border-dotted",none:""},b={complete:"bg-(--_mp-accent) text-(--_mp-on-accent)",current:"bg-(--_mp-accent) text-(--_mp-on-accent) shadow-[0_0_0_0.25rem_var(--_mp-accent-container)]",upcoming:"border-mp-outline text-mp-on-surface-variant border-2 bg-transparent"},v={complete:"border-(--_mp-accent)",current:"border-mp-outline-variant",upcoming:"border-mp-outline-variant"},h={complete:"text-mp-on-surface",current:"text-(--_mp-accent)",upcoming:"text-mp-on-surface-variant"};export const MPTimelineItem=/*@__PURE__*/t.forwardRef(function({title:n,meta:g,bullet:_,status:N,color:y,connector:z="solid",className:j,style:w,children:$,...C},M){const P=t.useContext(c),{index:B,last:k}=t.useContext(m),A=P?.size??"md",R=P?.orientation??"vertical",T=y??P?.color??"primary",I=P?.active??null,q=N??(null===I?"upcoming":B<I?"complete":B===I?"current":"upcoming"),D="horizontal"===R,E="none"!==z&&!k,F=e("span",{"aria-hidden":"true",className:["rounded-mp-full relative z-10 flex shrink-0 items-center justify-center","size-(--_mp-bullet) text-[calc(var(--_mp-bullet)*0.5)] leading-none font-medium","tabular-nums [&>svg]:size-[0.6em]",b[q],"transition-[background-color,border-color,box-shadow,color]","duration-(--mp-sys-motion-duration-short4)"].join(" "),children:_}),G=E?e("span",{"aria-hidden":"true",className:["pointer-events-none absolute",D?"start-(--_mp-bullet) top-[calc(var(--_mp-bullet)/2_-_1px)] end-0 border-t-2":"top-(--_mp-bullet) start-[calc(var(--_mp-bullet)/2_-_1px)] bottom-0 border-s-2",f[z],v[q]].filter(Boolean).join(" ")}):null,H=r("div",{className:"flex min-w-0 flex-col gap-0.5 "+(D?"mt-2":""),children:[a(n)||a(g)?r("div",{className:"flex flex-wrap items-baseline gap-x-2",children:[a(n)?e("span",{className:`${s[A]} ${h[q]}`,children:n}):null,a(g)?e("span",{className:`text-mp-on-surface-variant ${o}`,children:g}):null]}):null,a($)?e("div",{className:`text-mp-on-surface-variant ${i[A]}`,children:$}):null]});return r("li",{ref:M,"aria-current":"current"===q?"step":void 0,"data-status":q,className:["relative",D?`flex min-w-0 flex-1 flex-col ${k?"":x[A]}`:`flex ${d[A]} ${k?"":u[A]}`,j??""].filter(Boolean).join(" "),style:{"--_mp-bullet":p[A],...l(T),...w},...C,children:[G,F,H]})});export const MPTimeline=/*@__PURE__*/t.forwardRef(function({active:r,size:l="md",color:a="primary",orientation:o="vertical",render:i,className:s,style:p,children:d,...u},x){const f=t.Children.toArray(d),b=f.length,v=t.useMemo(()=>({size:l,orientation:o,color:a,active:r??null}),[l,o,a,r]),h=t.useMemo(()=>Array.from({length:b},(e,r)=>({index:r,last:r===b-1})),[b]),g=n({render:i??e("ol",{}),ref:x,props:{role:"list","data-mp-size":l,className:["mp-timeline flex","horizontal"===o?"flex-row":"flex-col",s??""].filter(Boolean).join(" "),style:p,children:f.map((r,t)=>e(m.Provider,{value:h[t],children:r},t)),...u}});return e(c.Provider,{value:v,children:g})});
@@ -1 +1 @@
1
- import*as p from"react";import{useRender as t}from"@base-ui/react/use-render";import{accentSlots as e}from"../../internal/accent";const r={h1:"[&.mp-typography]:text-mp-display-small",h2:"[&.mp-typography]:text-mp-headline-large",h3:"[&.mp-typography]:text-mp-headline-medium",h4:"[&.mp-typography]:text-mp-headline-small",h5:"[&.mp-typography]:text-mp-title-large",h6:"[&.mp-typography]:text-mp-title-medium",lead:"[&.mp-typography]:text-mp-title-large",body:"[&.mp-typography]:text-mp-body-large",caption:"[&.mp-typography]:text-mp-body-small",overline:"[&.mp-typography]:text-mp-label-small [&.mp-typography]:tracking-[0.08em] uppercase"},a={h1:"regular",h2:"regular",h3:"regular",h4:"regular",h5:"regular",h6:"medium",lead:"regular",body:"regular",caption:"regular",overline:"medium"},m={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",lead:"p",body:"p",caption:"span",overline:"span"},o=new Set(["caption","overline"]),y={h1:"[&.mp-typography]:mb-4",h2:"[&.mp-typography]:mb-3.5",h3:"[&.mp-typography]:mb-3",h4:"[&.mp-typography]:mb-2.5",h5:"[&.mp-typography]:mb-2",h6:"[&.mp-typography]:mb-2",lead:"[&.mp-typography]:mb-4",body:"[&.mp-typography]:mb-3",caption:"[&.mp-typography]:mb-2",overline:"[&.mp-typography]:mb-2"},h="[&.mp-typography]:mt-0 [&.mp-typography]:ms-0 [&.mp-typography]:me-0",l={regular:"[&.mp-typography]:font-normal",medium:"[&.mp-typography]:font-medium",semibold:"[&.mp-typography]:font-semibold",bold:"[&.mp-typography]:font-bold"},n={start:"text-start",center:"text-center",end:"text-end",justify:"text-justify"},g={1:"truncate",2:"line-clamp-2",3:"line-clamp-3",4:"line-clamp-4",5:"line-clamp-5",6:"line-clamp-6"};export const MPTypography=p.forwardRef(function({level:i="body",color:c,weight:d,align:s,lines:u,gutter:b=!1,render:x,className:f,style:v,children:j,...w},N){const k=["mp-typography",r[i],l[d??a[i]],h,b?y[i]:"[&.mp-typography]:mb-0",s?n[s]:"",u?g[u]??"line-clamp-6":"",c?"[&.mp-typography]:text-(--_mp-accent)":o.has(i)?"[&.mp-typography]:text-mp-on-surface-variant":"[&.mp-typography]:text-mp-on-surface",f??""].filter(Boolean).join(" ");return t({render:x??p.createElement(m[i]),ref:N,props:{className:k,style:c?{...e(c),...v}:v,children:j,...w}})});
1
+ import*as p from"react";import{useRender as t}from"@base-ui/react/use-render";import{accentSlots as e}from"../../internal/accent";const r={h1:"[&.mp-typography]:text-mp-display-small",h2:"[&.mp-typography]:text-mp-headline-large",h3:"[&.mp-typography]:text-mp-headline-medium",h4:"[&.mp-typography]:text-mp-headline-small",h5:"[&.mp-typography]:text-mp-title-large",h6:"[&.mp-typography]:text-mp-title-medium",lead:"[&.mp-typography]:text-mp-title-large",body:"[&.mp-typography]:text-mp-body-large",caption:"[&.mp-typography]:text-mp-body-small",overline:"[&.mp-typography]:text-mp-label-small [&.mp-typography]:tracking-[0.08em] uppercase"},a={h1:"regular",h2:"regular",h3:"regular",h4:"regular",h5:"regular",h6:"medium",lead:"regular",body:"regular",caption:"regular",overline:"medium"},m={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",lead:"p",body:"p",caption:"span",overline:"span"},o=new Set(["caption","overline"]),y={h1:"[&.mp-typography]:mb-4",h2:"[&.mp-typography]:mb-3.5",h3:"[&.mp-typography]:mb-3",h4:"[&.mp-typography]:mb-2.5",h5:"[&.mp-typography]:mb-2",h6:"[&.mp-typography]:mb-2",lead:"[&.mp-typography]:mb-4",body:"[&.mp-typography]:mb-3",caption:"[&.mp-typography]:mb-2",overline:"[&.mp-typography]:mb-2"},h="[&.mp-typography]:mt-0 [&.mp-typography]:ms-0 [&.mp-typography]:me-0",l={regular:"[&.mp-typography]:font-normal",medium:"[&.mp-typography]:font-medium",semibold:"[&.mp-typography]:font-semibold",bold:"[&.mp-typography]:font-bold"},n={start:"text-start",center:"text-center",end:"text-end",justify:"text-justify"},g={1:"truncate",2:"line-clamp-2",3:"line-clamp-3",4:"line-clamp-4",5:"line-clamp-5",6:"line-clamp-6"};export const MPTypography=/*@__PURE__*/p.forwardRef(function({level:i="body",color:c,weight:d,align:s,lines:u,gutter:b=!1,render:x,className:f,style:v,children:j,...w},N){const k=["mp-typography",r[i],l[d??a[i]],h,b?y[i]:"[&.mp-typography]:mb-0",s?n[s]:"",u?g[u]??"line-clamp-6":"",c?"[&.mp-typography]:text-(--_mp-accent)":o.has(i)?"[&.mp-typography]:text-mp-on-surface-variant":"[&.mp-typography]:text-mp-on-surface",f??""].filter(Boolean).join(" ");return t({render:x??p.createElement(m[i]),ref:N,props:{className:k,style:c?{...e(c),...v}:v,children:j,...w}})});
package/dist/index.d.ts CHANGED
@@ -1,4 +1,5 @@
1
1
  export * from './types';
2
+ export { registerMPMessages, type MPLocale, type MPMessages, type MPPartialMessages } from './internal/i18n';
2
3
  export * from './constants/icons';
3
4
  export * from './components/accordion';
4
5
  export * from './components/alert';
package/dist/index.js CHANGED
@@ -1 +1 @@
1
- export*from"./types";export*from"./constants/icons";export*from"./components/accordion";export*from"./components/alert";export*from"./components/animate-appear";export*from"./components/animate-blink";export*from"./components/animate-fade";export*from"./components/animate-grow";export*from"./components/animate-headline";export*from"./components/animate-lighting";export*from"./components/animate-marquee";export*from"./components/animate-rotate";export*from"./components/animate-slide";export*from"./components/animate-typing";export*from"./components/animate-zoom";export*from"./components/aspect-ratio";export*from"./components/avatar";export*from"./components/badge";export*from"./components/blockquote";export*from"./components/bottom-navigation";export*from"./components/box";export*from"./components/breadcrumb";export*from"./components/button";export*from"./components/button-group";export*from"./components/card";export*from"./components/carousel";export*from"./components/chat-bubble";export*from"./components/checkbox";export*from"./components/chip";export*from"./components/collapsible";export*from"./components/color-picker";export*from"./components/combobox";export*from"./components/container";export*from"./components/date-picker";export*from"./components/date-range-picker";export*from"./components/date-time-picker";export*from"./components/dialog";export*from"./components/divider";export*from"./components/drawer";export*from"./components/empty";export*from"./components/file-picker";export*from"./components/floating-action-button";export*from"./components/grid";export*from"./components/highlight";export*from"./components/icon";export*from"./components/icon-button";export*from"./components/list";export*from"./components/locale";export*from"./components/menu";export*from"./components/number-field";export*from"./components/otp-field";export*from"./components/overlay";export*from"./components/pagination";export*from"./components/panes";export*from"./components/pill";export*from"./components/popover";export*from"./components/progress-box";export*from"./components/progress-circular";export*from"./components/progress-linear";export*from"./components/radio-group";export*from"./components/rating";export*from"./components/segmented-button";export*from"./components/select";export*from"./components/shortcut";export*from"./components/skeleton";export*from"./components/slider";export*from"./components/snackbar";export*from"./components/spoiler";export*from"./components/switch";export*from"./components/table";export*from"./components/tabs";export*from"./components/text-field";export*from"./components/text-link";export*from"./components/time-picker";export*from"./components/timeline";export*from"./components/tooltip";export*from"./components/typography";
1
+ export*from"./types";export{registerMPMessages}from"./internal/i18n";export*from"./constants/icons";export*from"./components/accordion";export*from"./components/alert";export*from"./components/animate-appear";export*from"./components/animate-blink";export*from"./components/animate-fade";export*from"./components/animate-grow";export*from"./components/animate-headline";export*from"./components/animate-lighting";export*from"./components/animate-marquee";export*from"./components/animate-rotate";export*from"./components/animate-slide";export*from"./components/animate-typing";export*from"./components/animate-zoom";export*from"./components/aspect-ratio";export*from"./components/avatar";export*from"./components/badge";export*from"./components/blockquote";export*from"./components/bottom-navigation";export*from"./components/box";export*from"./components/breadcrumb";export*from"./components/button";export*from"./components/button-group";export*from"./components/card";export*from"./components/carousel";export*from"./components/chat-bubble";export*from"./components/checkbox";export*from"./components/chip";export*from"./components/collapsible";export*from"./components/color-picker";export*from"./components/combobox";export*from"./components/container";export*from"./components/date-picker";export*from"./components/date-range-picker";export*from"./components/date-time-picker";export*from"./components/dialog";export*from"./components/divider";export*from"./components/drawer";export*from"./components/empty";export*from"./components/file-picker";export*from"./components/floating-action-button";export*from"./components/grid";export*from"./components/highlight";export*from"./components/icon";export*from"./components/icon-button";export*from"./components/list";export*from"./components/locale";export*from"./components/menu";export*from"./components/number-field";export*from"./components/otp-field";export*from"./components/overlay";export*from"./components/pagination";export*from"./components/panes";export*from"./components/pill";export*from"./components/popover";export*from"./components/progress-box";export*from"./components/progress-circular";export*from"./components/progress-linear";export*from"./components/radio-group";export*from"./components/rating";export*from"./components/segmented-button";export*from"./components/select";export*from"./components/shortcut";export*from"./components/skeleton";export*from"./components/slider";export*from"./components/snackbar";export*from"./components/spoiler";export*from"./components/switch";export*from"./components/table";export*from"./components/tabs";export*from"./components/text-field";export*from"./components/text-link";export*from"./components/time-picker";export*from"./components/timeline";export*from"./components/tooltip";export*from"./components/typography";
@@ -1 +1 @@
1
- import*as t from"react";export const MPButtonGroupContext=t.createContext(null);
1
+ import*as t from"react";export const MPButtonGroupContext=/*@__PURE__*/t.createContext(null);
@@ -20,11 +20,26 @@
20
20
  *
21
21
  * Every component that reads this takes a `locale` and an override prop for the
22
22
  * strings themselves, so an unsupported language is never a dead end: `locale`
23
- * gets you a translation for free, `MPLocaleProvider` gets you one for the whole
23
+ * gets you a translation, `MPLocaleProvider` gets you one for the whole
24
24
  * application at once, and the prop gets you one for anything else.
25
25
  *
26
- * Nothing here is exported from `src/index.ts` — the public surface is
27
- * `MPLocaleProvider` and the per-component `labels` props.
26
+ * ## Why English is the only table in this file
27
+ *
28
+ * The other eighteen live under `src/locales/`, and nothing in the library
29
+ * imports them. They used to be here, and being here is what made them cost
30
+ * something: a component that says one word — `MPButton` says *Loading* — held a
31
+ * static import chain down to a table of every string in every language, and a
32
+ * bundler cannot drop data that something imports. Twenty kilobytes, on every
33
+ * consumer, for a word.
34
+ *
35
+ * So the table arrives from the outside instead. `registerMPMessages` below is
36
+ * how, `material-plus-ui/locales` is where from, and the only thing that changed
37
+ * for a reader is that the application now names the languages it speaks. Once
38
+ * it has, `locale="ko"` resolves through exactly the path it always did.
39
+ *
40
+ * The public surface is `registerMPMessages`, `MPLocaleProvider` and the
41
+ * per-component `labels` props; `resolveMessages` and `fillMessage` stay
42
+ * internal.
28
43
  */
29
44
  /**
30
45
  * One namespace per component, rather than one flat list of keys.
@@ -210,6 +225,52 @@ export interface MPMessages {
210
225
  notice: string;
211
226
  };
212
227
  }
228
+ /** A translation may fill in as much or as little of the table as it has. */
229
+ export type MPPartialMessages = {
230
+ [Namespace in keyof MPMessages]?: Partial<MPMessages[Namespace]>;
231
+ };
232
+ /**
233
+ * One language, ready to be handed to `registerMPMessages`.
234
+ *
235
+ * The tag travels with the table rather than beside it, so registering is
236
+ * `registerMPMessages(ko)` and not `registerMPMessages('ko', ko)` — one
237
+ * argument that cannot disagree with itself, and a shape an application can
238
+ * write by hand for a language this library does not ship.
239
+ */
240
+ export interface MPLocale {
241
+ /**
242
+ * The BCP 47 tag this table answers to, lowercased on the way in.
243
+ *
244
+ * Broad rather than narrow: `pt` serves a reader who asked for `pt-BR`, and a
245
+ * table registered as `pt-BR` would not serve one who asked for `pt`.
246
+ */
247
+ locale: string;
248
+ /**
249
+ * Other tags that should resolve to this same table.
250
+ *
251
+ * What `zh-hant` uses to answer for `zh-TW`, `zh-HK` and `zh-MO`: the same
252
+ * characters under three names, held once. An alias is registered with the
253
+ * table and disappears with it.
254
+ */
255
+ aliases?: string[];
256
+ /** The strings. Anything left out falls back to English, a namespace at a time. */
257
+ messages: MPPartialMessages;
258
+ }
259
+ /**
260
+ * Teaches the library a language.
261
+ *
262
+ * Variadic because registering one is the common case and registering four is
263
+ * the next one, and neither should need a loop at the call site. Call it once,
264
+ * at startup, before anything renders: it is module-level state, and a table
265
+ * that arrives after a component has already resolved its strings would be a
266
+ * table that only takes effect at the next re-render.
267
+ *
268
+ * Registering a tag that is already registered replaces it, which is what makes
269
+ * `registerMPMessages({ locale: 'ko', messages: { common: { close: '나가기' } } })`
270
+ * a workable way to correct one word without forking a file — although a
271
+ * component's own `labels` prop is the lighter tool for that.
272
+ */
273
+ export declare function registerMPMessages(...locales: MPLocale[]): void;
213
274
  /**
214
275
  * The strings for a locale, merged over English.
215
276
  *
@@ -1 +1 @@
1
- const e={common:{close:"Close",clear:"Clear",open:"Open",remove:"Remove",removeNamed:"Remove {label}",loading:"Loading"},textField:{showPassword:"Show the password",hidePassword:"Hide the password"},empty:{title:"Nothing here"},picker:{previousMonth:"Previous month",nextMonth:"Next month",previousYear:"Previous year",nextYear:"Next year",previousYears:"Previous years",nextYears:"Next years",chooseMonth:"Choose a month",chooseYear:"Choose a year",today:"Today",now:"Now",clear:"Clear",done:"Done",hour:"Hour",minute:"Minute",second:"Second",meridiem:"AM/PM",start:"Start",end:"End"},alert:{dismiss:"Dismiss"},chat:{sending:"Sending",sent:"Sent",delivered:"Delivered",read:"Read",failed:"Not sent",typing:"Typing"},spoiler:{reveal:"Reveal",hide:"Hide",notice:"Hidden so it is not read by accident"},pagination:{label:"Pagination",page:"Page {page}",status:"Page {page} of {total}",previous:"Previous page",next:"Next page",first:"First page",last:"Last page"},rating:{label:"Rating",value:"{value} out of {max}",empty:"Not rated"}},a={ko:{common:{close:"닫기",clear:"지우기",open:"열기",remove:"제거",removeNamed:"{label} 제거",loading:"불러오는 중"},textField:{showPassword:"비밀번호 표시",hidePassword:"비밀번호 숨기기"},empty:{title:"아무것도 없습니다"},picker:{previousMonth:"이전 달",nextMonth:"다음 달",previousYear:"이전 해",nextYear:"다음 해",previousYears:"이전 연도 목록",nextYears:"다음 연도 목록",chooseMonth:"월 선택",chooseYear:"연도 선택",today:"오늘",now:"지금",clear:"지우기",done:"완료",hour:"시",minute:"분",second:"초",meridiem:"오전/오후",start:"시작",end:"종료"},alert:{dismiss:"닫기"},chat:{sending:"보내는 중",sent:"보냄",delivered:"전달됨",read:"읽음",failed:"전송 실패",typing:"입력 중"},spoiler:{reveal:"보기",hide:"가리기",notice:"실수로 읽지 않도록 가려 두었습니다"},pagination:{label:"페이지 매기기",page:"{page}페이지",status:"{total}페이지 중 {page}페이지",previous:"이전 페이지",next:"다음 페이지",first:"첫 페이지",last:"마지막 페이지"},rating:{label:"별점",value:"{max}점 만점에 {value}점",empty:"평가 없음"}},ja:{common:{close:"閉じる",clear:"クリア",open:"開く",remove:"削除",removeNamed:"{label} を削除",loading:"読み込み中"},textField:{showPassword:"パスワードを表示",hidePassword:"パスワードを非表示"},empty:{title:"何もありません"},picker:{previousMonth:"前の月",nextMonth:"次の月",previousYear:"前の年",nextYear:"次の年",previousYears:"前の年の一覧",nextYears:"次の年の一覧",chooseMonth:"月を選択",chooseYear:"年を選択",today:"今日",now:"現在",clear:"クリア",done:"完了",hour:"時",minute:"分",second:"秒",meridiem:"午前/午後",start:"開始",end:"終了"},alert:{dismiss:"閉じる"},chat:{sending:"送信中",sent:"送信済み",delivered:"配信済み",read:"既読",failed:"送信できませんでした",typing:"入力中"},spoiler:{reveal:"表示する",hide:"隠す",notice:"うっかり読まないように隠してあります"},pagination:{label:"ページ送り",page:"{page}ページ",status:"{total}ページ中{page}ページ",previous:"前のページ",next:"次のページ",first:"最初のページ",last:"最後のページ"},rating:{label:"評価",value:"{max}段階中{value}",empty:"未評価"}},"zh-hans":{common:{close:"关闭",clear:"清除",open:"打开",remove:"移除",removeNamed:"移除 {label}",loading:"加载中"},textField:{showPassword:"显示密码",hidePassword:"隐藏密码"},empty:{title:"暂无内容"},picker:{previousMonth:"上个月",nextMonth:"下个月",previousYear:"上一年",nextYear:"下一年",previousYears:"上一页年份",nextYears:"下一页年份",chooseMonth:"选择月份",chooseYear:"选择年份",today:"今天",now:"此刻",clear:"清除",done:"完成",hour:"小时",minute:"分钟",second:"秒",meridiem:"上午/下午",start:"开始",end:"结束"},alert:{dismiss:"关闭"},chat:{sending:"发送中",sent:"已发送",delivered:"已送达",read:"已读",failed:"未发送",typing:"正在输入"},spoiler:{reveal:"显示",hide:"隐藏",notice:"已隐藏,以免不小心读到"},pagination:{label:"分页",page:"第 {page} 页",status:"第 {page} 页,共 {total} 页",previous:"上一页",next:"下一页",first:"第一页",last:"最后一页"},rating:{label:"评分",value:"{max} 分中的 {value} 分",empty:"未评分"}},"zh-hant":{common:{close:"關閉",clear:"清除",open:"開啟",remove:"移除",removeNamed:"移除 {label}",loading:"載入中"},textField:{showPassword:"顯示密碼",hidePassword:"隱藏密碼"},empty:{title:"暫無內容"},picker:{previousMonth:"上個月",nextMonth:"下個月",previousYear:"上一年",nextYear:"下一年",previousYears:"上一頁年份",nextYears:"下一頁年份",chooseMonth:"選擇月份",chooseYear:"選擇年份",today:"今天",now:"此刻",clear:"清除",done:"完成",hour:"小時",minute:"分鐘",second:"秒",meridiem:"上午/下午",start:"開始",end:"結束"},alert:{dismiss:"關閉"},chat:{sending:"傳送中",sent:"已傳送",delivered:"已送達",read:"已讀",failed:"未傳送",typing:"正在輸入"},spoiler:{reveal:"顯示",hide:"隱藏",notice:"已隱藏,以免不小心讀到"},pagination:{label:"分頁",page:"第 {page} 頁",status:"第 {page} 頁,共 {total} 頁",previous:"上一頁",next:"下一頁",first:"第一頁",last:"最後一頁"},rating:{label:"評分",value:"{max} 分中的 {value} 分",empty:"未評分"}},es:{common:{close:"Cerrar",clear:"Borrar",open:"Abrir",remove:"Quitar",removeNamed:"Quitar {label}",loading:"Cargando"},textField:{showPassword:"Mostrar la contraseña",hidePassword:"Ocultar la contraseña"},empty:{title:"No hay nada aquí"},picker:{previousMonth:"Mes anterior",nextMonth:"Mes siguiente",previousYear:"Año anterior",nextYear:"Año siguiente",previousYears:"Años anteriores",nextYears:"Años siguientes",chooseMonth:"Elegir un mes",chooseYear:"Elegir un año",today:"Hoy",now:"Ahora",clear:"Borrar",done:"Listo",hour:"Hora",minute:"Minuto",second:"Segundo",meridiem:"a. m./p. m.",start:"Inicio",end:"Fin"},alert:{dismiss:"Cerrar"},chat:{sending:"Enviando",sent:"Enviado",delivered:"Entregado",read:"Leído",failed:"No enviado",typing:"Escribiendo"},spoiler:{reveal:"Mostrar",hide:"Ocultar",notice:"Oculto para que no se lea por accidente"},pagination:{label:"Paginación",page:"Página {page}",status:"Página {page} de {total}",previous:"Página anterior",next:"Página siguiente",first:"Primera página",last:"Última página"},rating:{label:"Valoración",value:"{value} de {max}",empty:"Sin valorar"}},pt:{common:{close:"Fechar",clear:"Limpar",open:"Abrir",remove:"Remover",removeNamed:"Remover {label}",loading:"Carregando"},textField:{showPassword:"Mostrar a senha",hidePassword:"Ocultar a senha"},empty:{title:"Não há nada aqui"},picker:{previousMonth:"Mês anterior",nextMonth:"Próximo mês",previousYear:"Ano anterior",nextYear:"Próximo ano",previousYears:"Anos anteriores",nextYears:"Próximos anos",chooseMonth:"Escolher um mês",chooseYear:"Escolher um ano",today:"Hoje",now:"Agora",clear:"Limpar",done:"Concluído",hour:"Hora",minute:"Minuto",second:"Segundo",meridiem:"AM/PM",start:"Início",end:"Fim"},alert:{dismiss:"Fechar"},chat:{sending:"Enviando",sent:"Enviado",delivered:"Entregue",read:"Lido",failed:"Não enviado",typing:"Digitando"},spoiler:{reveal:"Mostrar",hide:"Ocultar",notice:"Oculto para não ser lido por acidente"},pagination:{label:"Paginação",page:"Página {page}",status:"Página {page} de {total}",previous:"Página anterior",next:"Próxima página",first:"Primeira página",last:"Última página"},rating:{label:"Avaliação",value:"{value} de {max}",empty:"Sem avaliação"}},fr:{common:{close:"Fermer",clear:"Effacer",open:"Ouvrir",remove:"Supprimer",removeNamed:"Supprimer {label}",loading:"Chargement"},textField:{showPassword:"Afficher le mot de passe",hidePassword:"Masquer le mot de passe"},empty:{title:"Il n'y a rien ici"},picker:{previousMonth:"Mois précédent",nextMonth:"Mois suivant",previousYear:"Année précédente",nextYear:"Année suivante",previousYears:"Années précédentes",nextYears:"Années suivantes",chooseMonth:"Choisir un mois",chooseYear:"Choisir une année",today:"Aujourd'hui",now:"Maintenant",clear:"Effacer",done:"Terminé",hour:"Heure",minute:"Minute",second:"Seconde",meridiem:"AM/PM",start:"Début",end:"Fin"},alert:{dismiss:"Fermer"},chat:{sending:"Envoi en cours",sent:"Envoyé",delivered:"Distribué",read:"Lu",failed:"Non envoyé",typing:"En train d'écrire"},spoiler:{reveal:"Afficher",hide:"Masquer",notice:"Masqué pour ne pas être lu par accident"},pagination:{label:"Pagination",page:"Page {page}",status:"Page {page} sur {total}",previous:"Page précédente",next:"Page suivante",first:"Première page",last:"Dernière page"},rating:{label:"Note",value:"{value} sur {max}",empty:"Non noté"}},de:{common:{close:"Schließen",clear:"Löschen",open:"Öffnen",remove:"Entfernen",removeNamed:"{label} entfernen",loading:"Wird geladen"},textField:{showPassword:"Passwort anzeigen",hidePassword:"Passwort verbergen"},empty:{title:"Nichts vorhanden"},picker:{previousMonth:"Voriger Monat",nextMonth:"Nächster Monat",previousYear:"Voriges Jahr",nextYear:"Nächstes Jahr",previousYears:"Vorige Jahre",nextYears:"Nächste Jahre",chooseMonth:"Monat auswählen",chooseYear:"Jahr auswählen",today:"Heute",now:"Jetzt",clear:"Löschen",done:"Fertig",hour:"Stunde",minute:"Minute",second:"Sekunde",meridiem:"AM/PM",start:"Beginn",end:"Ende"},alert:{dismiss:"Schließen"},chat:{sending:"Wird gesendet",sent:"Gesendet",delivered:"Zugestellt",read:"Gelesen",failed:"Nicht gesendet",typing:"Schreibt"},spoiler:{reveal:"Anzeigen",hide:"Verbergen",notice:"Verborgen, damit es nicht versehentlich gelesen wird"},pagination:{label:"Seitennummerierung",page:"Seite {page}",status:"Seite {page} von {total}",previous:"Vorherige Seite",next:"Nächste Seite",first:"Erste Seite",last:"Letzte Seite"},rating:{label:"Bewertung",value:"{value} von {max}",empty:"Nicht bewertet"}},it:{common:{close:"Chiudi",clear:"Cancella",open:"Apri",remove:"Rimuovi",removeNamed:"Rimuovi {label}",loading:"Caricamento"},textField:{showPassword:"Mostra la password",hidePassword:"Nascondi la password"},empty:{title:"Non c'è nulla qui"},picker:{previousMonth:"Mese precedente",nextMonth:"Mese successivo",previousYear:"Anno precedente",nextYear:"Anno successivo",previousYears:"Anni precedenti",nextYears:"Anni successivi",chooseMonth:"Scegli un mese",chooseYear:"Scegli un anno",today:"Oggi",now:"Adesso",clear:"Cancella",done:"Fatto",hour:"Ora",minute:"Minuto",second:"Secondo",meridiem:"AM/PM",start:"Inizio",end:"Fine"},alert:{dismiss:"Chiudi"},chat:{sending:"Invio in corso",sent:"Inviato",delivered:"Consegnato",read:"Letto",failed:"Non inviato",typing:"Sta scrivendo"},spoiler:{reveal:"Mostra",hide:"Nascondi",notice:"Nascosto per non essere letto per sbaglio"},pagination:{label:"Impaginazione",page:"Pagina {page}",status:"Pagina {page} di {total}",previous:"Pagina precedente",next:"Pagina successiva",first:"Prima pagina",last:"Ultima pagina"},rating:{label:"Valutazione",value:"{value} su {max}",empty:"Non valutato"}},nl:{common:{close:"Sluiten",clear:"Wissen",open:"Openen",remove:"Verwijderen",removeNamed:"{label} verwijderen",loading:"Laden"},textField:{showPassword:"Wachtwoord tonen",hidePassword:"Wachtwoord verbergen"},empty:{title:"Hier is niets"},picker:{previousMonth:"Vorige maand",nextMonth:"Volgende maand",previousYear:"Vorig jaar",nextYear:"Volgend jaar",previousYears:"Vorige jaren",nextYears:"Volgende jaren",chooseMonth:"Kies een maand",chooseYear:"Kies een jaar",today:"Vandaag",now:"Nu",clear:"Wissen",done:"Klaar",hour:"Uur",minute:"Minuut",second:"Seconde",meridiem:"AM/PM",start:"Begin",end:"Einde"},alert:{dismiss:"Sluiten"},chat:{sending:"Verzenden",sent:"Verzonden",delivered:"Bezorgd",read:"Gelezen",failed:"Niet verzonden",typing:"Aan het typen"},spoiler:{reveal:"Tonen",hide:"Verbergen",notice:"Verborgen zodat het niet per ongeluk wordt gelezen"},pagination:{label:"Paginering",page:"Pagina {page}",status:"Pagina {page} van {total}",previous:"Vorige pagina",next:"Volgende pagina",first:"Eerste pagina",last:"Laatste pagina"},rating:{label:"Beoordeling",value:"{value} van {max}",empty:"Niet beoordeeld"}},pl:{common:{close:"Zamknij",clear:"Wyczyść",open:"Otwórz",remove:"Usuń",removeNamed:"Usuń {label}",loading:"Ładowanie"},textField:{showPassword:"Pokaż hasło",hidePassword:"Ukryj hasło"},empty:{title:"Nic tu nie ma"},picker:{previousMonth:"Poprzedni miesiąc",nextMonth:"Następny miesiąc",previousYear:"Poprzedni rok",nextYear:"Następny rok",previousYears:"Poprzednie lata",nextYears:"Następne lata",chooseMonth:"Wybierz miesiąc",chooseYear:"Wybierz rok",today:"Dzisiaj",now:"Teraz",clear:"Wyczyść",done:"Gotowe",hour:"Godzina",minute:"Minuta",second:"Sekunda",meridiem:"AM/PM",start:"Początek",end:"Koniec"},alert:{dismiss:"Zamknij"},chat:{sending:"Wysyłanie",sent:"Wysłano",delivered:"Dostarczono",read:"Przeczytano",failed:"Nie wysłano",typing:"Pisze"},spoiler:{reveal:"Pokaż",hide:"Ukryj",notice:"Ukryte, aby nie przeczytać przez przypadek"},pagination:{label:"Paginacja",page:"Strona {page}",status:"Strona {page} z {total}",previous:"Poprzednia strona",next:"Następna strona",first:"Pierwsza strona",last:"Ostatnia strona"},rating:{label:"Ocena",value:"{value} z {max}",empty:"Brak oceny"}},ru:{common:{close:"Закрыть",clear:"Очистить",open:"Открыть",remove:"Удалить",removeNamed:"Удалить {label}",loading:"Загрузка"},textField:{showPassword:"Показать пароль",hidePassword:"Скрыть пароль"},empty:{title:"Здесь ничего нет"},picker:{previousMonth:"Предыдущий месяц",nextMonth:"Следующий месяц",previousYear:"Предыдущий год",nextYear:"Следующий год",previousYears:"Предыдущие годы",nextYears:"Следующие годы",chooseMonth:"Выбрать месяц",chooseYear:"Выбрать год",today:"Сегодня",now:"Сейчас",clear:"Очистить",done:"Готово",hour:"Часы",minute:"Минуты",second:"Секунды",meridiem:"ДП/ПП",start:"Начало",end:"Конец"},alert:{dismiss:"Закрыть"},chat:{sending:"Отправка",sent:"Отправлено",delivered:"Доставлено",read:"Прочитано",failed:"Не отправлено",typing:"Печатает"},spoiler:{reveal:"Показать",hide:"Скрыть",notice:"Скрыто, чтобы не прочитать случайно"},pagination:{label:"Постраничная навигация",page:"Страница {page}",status:"Страница {page} из {total}",previous:"Предыдущая страница",next:"Следующая страница",first:"Первая страница",last:"Последняя страница"},rating:{label:"Оценка",value:"{value} из {max}",empty:"Без оценки"}},tr:{common:{close:"Kapat",clear:"Temizle",open:"Aç",remove:"Kaldır",removeNamed:"{label} kaldır",loading:"Yükleniyor"},textField:{showPassword:"Parolayı göster",hidePassword:"Parolayı gizle"},empty:{title:"Burada bir şey yok"},picker:{previousMonth:"Önceki ay",nextMonth:"Sonraki ay",previousYear:"Önceki yıl",nextYear:"Sonraki yıl",previousYears:"Önceki yıllar",nextYears:"Sonraki yıllar",chooseMonth:"Ay seçin",chooseYear:"Yıl seçin",today:"Bugün",now:"Şimdi",clear:"Temizle",done:"Tamam",hour:"Saat",minute:"Dakika",second:"Saniye",meridiem:"ÖÖ/ÖS",start:"Başlangıç",end:"Bitiş"},alert:{dismiss:"Kapat"},chat:{sending:"Gönderiliyor",sent:"Gönderildi",delivered:"İletildi",read:"Okundu",failed:"Gönderilemedi",typing:"Yazıyor"},spoiler:{reveal:"Göster",hide:"Gizle",notice:"Yanlışlıkla okunmasın diye gizlendi"},pagination:{label:"Sayfalama",page:"Sayfa {page}",status:"{total} sayfadan {page}. sayfa",previous:"Önceki sayfa",next:"Sonraki sayfa",first:"İlk sayfa",last:"Son sayfa"},rating:{label:"Değerlendirme",value:"{max} üzerinden {value}",empty:"Değerlendirilmedi"}},ar:{common:{close:"إغلاق",clear:"مسح",open:"فتح",remove:"إزالة",removeNamed:"إزالة {label}",loading:"جارٍ التحميل"},textField:{showPassword:"إظهار كلمة المرور",hidePassword:"إخفاء كلمة المرور"},empty:{title:"لا يوجد شيء هنا"},picker:{previousMonth:"الشهر السابق",nextMonth:"الشهر التالي",previousYear:"السنة السابقة",nextYear:"السنة التالية",previousYears:"السنوات السابقة",nextYears:"السنوات التالية",chooseMonth:"اختيار شهر",chooseYear:"اختيار سنة",today:"اليوم",now:"الآن",clear:"مسح",done:"تم",hour:"الساعة",minute:"الدقيقة",second:"الثانية",meridiem:"ص/م",start:"البداية",end:"النهاية"},alert:{dismiss:"إغلاق"},chat:{sending:"جارٍ الإرسال",sent:"تم الإرسال",delivered:"تم التسليم",read:"تمت القراءة",failed:"لم يتم الإرسال",typing:"يكتب الآن"},spoiler:{reveal:"إظهار",hide:"إخفاء",notice:"مخفي حتى لا يُقرأ بالخطأ"},pagination:{label:"ترقيم الصفحات",page:"الصفحة {page}",status:"الصفحة {page} من {total}",previous:"الصفحة السابقة",next:"الصفحة التالية",first:"الصفحة الأولى",last:"الصفحة الأخيرة"},rating:{label:"التقييم",value:"{value} من {max}",empty:"بدون تقييم"}},hi:{common:{close:"बंद करें",clear:"हटाएँ",open:"खोलें",remove:"निकालें",removeNamed:"{label} निकालें",loading:"लोड हो रहा है"},textField:{showPassword:"पासवर्ड दिखाएँ",hidePassword:"पासवर्ड छिपाएँ"},empty:{title:"यहाँ कुछ नहीं है"},picker:{previousMonth:"पिछला महीना",nextMonth:"अगला महीना",previousYear:"पिछला वर्ष",nextYear:"अगला वर्ष",previousYears:"पिछले वर्ष",nextYears:"अगले वर्ष",chooseMonth:"महीना चुनें",chooseYear:"वर्ष चुनें",today:"आज",now:"अभी",clear:"हटाएँ",done:"हो गया",hour:"घंटा",minute:"मिनट",second:"सेकंड",meridiem:"AM/PM",start:"प्रारंभ",end:"समाप्ति"},alert:{dismiss:"बंद करें"},chat:{sending:"भेजा जा रहा है",sent:"भेजा गया",delivered:"पहुँच गया",read:"पढ़ लिया गया",failed:"नहीं भेजा गया",typing:"टाइप कर रहे हैं"},spoiler:{reveal:"दिखाएँ",hide:"छिपाएँ",notice:"गलती से न पढ़ लिया जाए इसलिए छिपाया गया है"},pagination:{label:"पृष्ठ क्रमांकन",page:"पृष्ठ {page}",status:"{total} में से पृष्ठ {page}",previous:"पिछला पृष्ठ",next:"अगला पृष्ठ",first:"पहला पृष्ठ",last:"अंतिम पृष्ठ"},rating:{label:"रेटिंग",value:"{max} में से {value}",empty:"रेटिंग नहीं दी गई"}},id:{common:{close:"Tutup",clear:"Bersihkan",open:"Buka",remove:"Hapus",removeNamed:"Hapus {label}",loading:"Memuat"},textField:{showPassword:"Tampilkan kata sandi",hidePassword:"Sembunyikan kata sandi"},empty:{title:"Tidak ada apa-apa di sini"},picker:{previousMonth:"Bulan sebelumnya",nextMonth:"Bulan berikutnya",previousYear:"Tahun sebelumnya",nextYear:"Tahun berikutnya",previousYears:"Tahun-tahun sebelumnya",nextYears:"Tahun-tahun berikutnya",chooseMonth:"Pilih bulan",chooseYear:"Pilih tahun",today:"Hari ini",now:"Sekarang",clear:"Hapus",done:"Selesai",hour:"Jam",minute:"Menit",second:"Detik",meridiem:"AM/PM",start:"Mulai",end:"Akhir"},alert:{dismiss:"Tutup"},chat:{sending:"Mengirim",sent:"Terkirim",delivered:"Diterima",read:"Dibaca",failed:"Gagal terkirim",typing:"Sedang mengetik"},spoiler:{reveal:"Tampilkan",hide:"Sembunyikan",notice:"Disembunyikan agar tidak terbaca tanpa sengaja"},pagination:{label:"Penomoran halaman",page:"Halaman {page}",status:"Halaman {page} dari {total}",previous:"Halaman sebelumnya",next:"Halaman berikutnya",first:"Halaman pertama",last:"Halaman terakhir"},rating:{label:"Peringkat",value:"{value} dari {max}",empty:"Belum dinilai"}},vi:{common:{close:"Đóng",clear:"Xóa",open:"Mở",remove:"Gỡ bỏ",removeNamed:"Gỡ bỏ {label}",loading:"Đang tải"},textField:{showPassword:"Hiện mật khẩu",hidePassword:"Ẩn mật khẩu"},empty:{title:"Không có gì ở đây"},picker:{previousMonth:"Tháng trước",nextMonth:"Tháng sau",previousYear:"Năm trước",nextYear:"Năm sau",previousYears:"Các năm trước",nextYears:"Các năm sau",chooseMonth:"Chọn tháng",chooseYear:"Chọn năm",today:"Hôm nay",now:"Bây giờ",clear:"Xóa",done:"Xong",hour:"Giờ",minute:"Phút",second:"Giây",meridiem:"SA/CH",start:"Bắt đầu",end:"Kết thúc"},alert:{dismiss:"Đóng"},chat:{sending:"Đang gửi",sent:"Đã gửi",delivered:"Đã nhận",read:"Đã đọc",failed:"Chưa gửi được",typing:"Đang nhập"},spoiler:{reveal:"Hiện",hide:"Ẩn",notice:"Đã ẩn để không vô tình đọc phải"},pagination:{label:"Phân trang",page:"Trang {page}",status:"Trang {page} trên {total}",previous:"Trang trước",next:"Trang sau",first:"Trang đầu",last:"Trang cuối"},rating:{label:"Đánh giá",value:"{value} trên {max}",empty:"Chưa đánh giá"}},th:{common:{close:"ปิด",clear:"ล้าง",open:"เปิด",remove:"ลบ",removeNamed:"ลบ {label}",loading:"กำลังโหลด"},textField:{showPassword:"แสดงรหัสผ่าน",hidePassword:"ซ่อนรหัสผ่าน"},empty:{title:"ไม่มีอะไรที่นี่"},picker:{previousMonth:"เดือนก่อนหน้า",nextMonth:"เดือนถัดไป",previousYear:"ปีก่อนหน้า",nextYear:"ปีถัดไป",previousYears:"ชุดปีก่อนหน้า",nextYears:"ชุดปีถัดไป",chooseMonth:"เลือกเดือน",chooseYear:"เลือกปี",today:"วันนี้",now:"ตอนนี้",clear:"ล้าง",done:"เสร็จสิ้น",hour:"ชั่วโมง",minute:"นาที",second:"วินาที",meridiem:"AM/PM",start:"เริ่ม",end:"สิ้นสุด"},alert:{dismiss:"ปิด"},chat:{sending:"กำลังส่ง",sent:"ส่งแล้ว",delivered:"ส่งถึงแล้ว",read:"อ่านแล้ว",failed:"ส่งไม่สำเร็จ",typing:"กำลังพิมพ์"},spoiler:{reveal:"แสดง",hide:"ซ่อน",notice:"ซ่อนไว้เพื่อไม่ให้อ่านโดยบังเอิญ"},pagination:{label:"การแบ่งหน้า",page:"หน้า {page}",status:"หน้า {page} จาก {total}",previous:"หน้าก่อนหน้า",next:"หน้าถัดไป",first:"หน้าแรก",last:"หน้าสุดท้าย"},rating:{label:"คะแนน",value:"{value} จาก {max}",empty:"ยังไม่ได้ให้คะแนน"}}},n={zh:"zh-hans","zh-cn":"zh-hans","zh-my":"zh-hans","zh-sg":"zh-hans","zh-hk":"zh-hant","zh-mo":"zh-hant","zh-tw":"zh-hant"};const i=new Map([["",e]]);export function resolveMessages(t){const o=t?.trim()??"",r=i.get(o);if(r)return r;const s=function(e){const a=e.toLowerCase().split(/[-_]/).filter(Boolean),n=a[0];if(!n)return[];const i=a.slice(1),t=i.find(e=>/^[a-z]{4}$/.test(e)),o=i.find(e=>/^([a-z]{2}|\d{3})$/.test(e));return[t?`${n}-${t}`:"",o?`${n}-${o}`:"",n].filter(Boolean)}(o).map(e=>a[e]??a[n[e]??""]).find(Boolean),l=s?{common:{...e.common,...s.common},textField:{...e.textField,...s.textField},empty:{...e.empty,...s.empty},picker:{...e.picker,...s.picker},alert:{...e.alert,...s.alert},chat:{...e.chat,...s.chat},pagination:{...e.pagination,...s.pagination},rating:{...e.rating,...s.rating},spoiler:{...e.spoiler,...s.spoiler}}:e;return i.set(o,l),l}export function fillMessage(e,a){return e.replace(/\{(\w+)\}/g,(e,n)=>a[n]??e)}
1
+ const e={common:{close:"Close",clear:"Clear",open:"Open",remove:"Remove",removeNamed:"Remove {label}",loading:"Loading"},textField:{showPassword:"Show the password",hidePassword:"Hide the password"},empty:{title:"Nothing here"},picker:{previousMonth:"Previous month",nextMonth:"Next month",previousYear:"Previous year",nextYear:"Next year",previousYears:"Previous years",nextYears:"Next years",chooseMonth:"Choose a month",chooseYear:"Choose a year",today:"Today",now:"Now",clear:"Clear",done:"Done",hour:"Hour",minute:"Minute",second:"Second",meridiem:"AM/PM",start:"Start",end:"End"},alert:{dismiss:"Dismiss"},chat:{sending:"Sending",sent:"Sent",delivered:"Delivered",read:"Read",failed:"Not sent",typing:"Typing"},spoiler:{reveal:"Reveal",hide:"Hide",notice:"Hidden so it is not read by accident"},pagination:{label:"Pagination",page:"Page {page}",status:"Page {page} of {total}",previous:"Previous page",next:"Next page",first:"First page",last:"Last page"},rating:{label:"Rating",value:"{value} out of {max}",empty:"Not rated"}},t=new Map;export function registerMPMessages(...a){for(const e of a){t.set(e.locale.toLowerCase(),e.messages);for(const o of e.aliases??[])t.set(o.toLowerCase(),e.messages)}o.clear(),o.set("",e)}const o=new Map([["",e]]);export function resolveMessages(a){const s=a?.trim()??"",n=o.get(s);if(n)return n;const r=function(e){const t=e.toLowerCase().split(/[-_]/).filter(Boolean),o=t[0];if(!o)return[];const a=t.slice(1),s=a.find(e=>/^[a-z]{4}$/.test(e)),n=a.find(e=>/^([a-z]{2}|\d{3})$/.test(e));return[s?`${o}-${s}`:"",n?`${o}-${n}`:"",o].filter(Boolean)}(s).map(e=>t.get(e)).find(Boolean),i=r?{common:{...e.common,...r.common},textField:{...e.textField,...r.textField},empty:{...e.empty,...r.empty},picker:{...e.picker,...r.picker},alert:{...e.alert,...r.alert},chat:{...e.chat,...r.chat},pagination:{...e.pagination,...r.pagination},rating:{...e.rating,...r.rating},spoiler:{...e.spoiler,...r.spoiler}}:e;return o.set(s,i),i}export function fillMessage(e,t){return e.replace(/\{(\w+)\}/g,(e,o)=>t[o]??e)}
@@ -1 +1 @@
1
- import*as e from"react";import{resolveMessages as t}from"./i18n";export const MPLocaleContext=e.createContext(void 0);export function useMPLocale(t){const o=e.useContext(MPLocaleContext);return t??o}export function useMPMessages(o,n,r){return e.useMemo(()=>{const e=t(n)[o];return r?{...e,...r}:e},[o,n,r])}
1
+ import*as e from"react";import{resolveMessages as t}from"./i18n";export const MPLocaleContext=/*@__PURE__*/e.createContext(void 0);export function useMPLocale(t){const o=e.useContext(MPLocaleContext);return t??o}export function useMPMessages(o,n,r){return e.useMemo(()=>{const e=t(n)[o];return r?{...e,...r}:e},[o,n,r])}
@@ -1 +1 @@
1
- import*as t from"react";export const MPMenuContext=t.createContext({size:"md",color:"primary"});
1
+ import*as t from"react";export const MPMenuContext=/*@__PURE__*/t.createContext({size:"md",color:"primary"});
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Arabic — العربية.
3
+ *
4
+ * One of the tables `material-plus-ui/locales` holds. Nothing in the library
5
+ * imports it: a translation reaches a component only once the application has
6
+ * handed it over, which is what keeps eighteen languages out of a bundle that
7
+ * needs one. See `internal/i18n.ts` for the whole of that reasoning.
8
+ *
9
+ * import { registerMPMessages } from 'material-plus-ui';
10
+ * import { ar } from 'material-plus-ui/locales/ar';
11
+ *
12
+ * registerMPMessages(ar);
13
+ *
14
+ * Anything this table leaves out falls back to English, a namespace at a time.
15
+ */
16
+ import type { MPLocale } from '../internal/i18n';
17
+ export declare const ar: MPLocale;
@@ -0,0 +1 @@
1
+ export const ar={locale:"ar",messages:{common:{close:"إغلاق",clear:"مسح",open:"فتح",remove:"إزالة",removeNamed:"إزالة {label}",loading:"جارٍ التحميل"},textField:{showPassword:"إظهار كلمة المرور",hidePassword:"إخفاء كلمة المرور"},empty:{title:"لا يوجد شيء هنا"},picker:{previousMonth:"الشهر السابق",nextMonth:"الشهر التالي",previousYear:"السنة السابقة",nextYear:"السنة التالية",previousYears:"السنوات السابقة",nextYears:"السنوات التالية",chooseMonth:"اختيار شهر",chooseYear:"اختيار سنة",today:"اليوم",now:"الآن",clear:"مسح",done:"تم",hour:"الساعة",minute:"الدقيقة",second:"الثانية",meridiem:"ص/م",start:"البداية",end:"النهاية"},alert:{dismiss:"إغلاق"},chat:{sending:"جارٍ الإرسال",sent:"تم الإرسال",delivered:"تم التسليم",read:"تمت القراءة",failed:"لم يتم الإرسال",typing:"يكتب الآن"},spoiler:{reveal:"إظهار",hide:"إخفاء",notice:"مخفي حتى لا يُقرأ بالخطأ"},pagination:{label:"ترقيم الصفحات",page:"الصفحة {page}",status:"الصفحة {page} من {total}",previous:"الصفحة السابقة",next:"الصفحة التالية",first:"الصفحة الأولى",last:"الصفحة الأخيرة"},rating:{label:"التقييم",value:"{value} من {max}",empty:"بدون تقييم"}}};
@@ -0,0 +1,17 @@
1
+ /**
2
+ * German — Deutsch.
3
+ *
4
+ * One of the tables `material-plus-ui/locales` holds. Nothing in the library
5
+ * imports it: a translation reaches a component only once the application has
6
+ * handed it over, which is what keeps eighteen languages out of a bundle that
7
+ * needs one. See `internal/i18n.ts` for the whole of that reasoning.
8
+ *
9
+ * import { registerMPMessages } from 'material-plus-ui';
10
+ * import { de } from 'material-plus-ui/locales/de';
11
+ *
12
+ * registerMPMessages(de);
13
+ *
14
+ * Anything this table leaves out falls back to English, a namespace at a time.
15
+ */
16
+ import type { MPLocale } from '../internal/i18n';
17
+ export declare const de: MPLocale;
@@ -0,0 +1 @@
1
+ export const de={locale:"de",messages:{common:{close:"Schließen",clear:"Löschen",open:"Öffnen",remove:"Entfernen",removeNamed:"{label} entfernen",loading:"Wird geladen"},textField:{showPassword:"Passwort anzeigen",hidePassword:"Passwort verbergen"},empty:{title:"Nichts vorhanden"},picker:{previousMonth:"Voriger Monat",nextMonth:"Nächster Monat",previousYear:"Voriges Jahr",nextYear:"Nächstes Jahr",previousYears:"Vorige Jahre",nextYears:"Nächste Jahre",chooseMonth:"Monat auswählen",chooseYear:"Jahr auswählen",today:"Heute",now:"Jetzt",clear:"Löschen",done:"Fertig",hour:"Stunde",minute:"Minute",second:"Sekunde",meridiem:"AM/PM",start:"Beginn",end:"Ende"},alert:{dismiss:"Schließen"},chat:{sending:"Wird gesendet",sent:"Gesendet",delivered:"Zugestellt",read:"Gelesen",failed:"Nicht gesendet",typing:"Schreibt"},spoiler:{reveal:"Anzeigen",hide:"Verbergen",notice:"Verborgen, damit es nicht versehentlich gelesen wird"},pagination:{label:"Seitennummerierung",page:"Seite {page}",status:"Seite {page} von {total}",previous:"Vorherige Seite",next:"Nächste Seite",first:"Erste Seite",last:"Letzte Seite"},rating:{label:"Bewertung",value:"{value} von {max}",empty:"Nicht bewertet"}}};
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Spanish — Español.
3
+ *
4
+ * One of the tables `material-plus-ui/locales` holds. Nothing in the library
5
+ * imports it: a translation reaches a component only once the application has
6
+ * handed it over, which is what keeps eighteen languages out of a bundle that
7
+ * needs one. See `internal/i18n.ts` for the whole of that reasoning.
8
+ *
9
+ * import { registerMPMessages } from 'material-plus-ui';
10
+ * import { es } from 'material-plus-ui/locales/es';
11
+ *
12
+ * registerMPMessages(es);
13
+ *
14
+ * Anything this table leaves out falls back to English, a namespace at a time.
15
+ */
16
+ import type { MPLocale } from '../internal/i18n';
17
+ export declare const es: MPLocale;
@@ -0,0 +1 @@
1
+ export const es={locale:"es",messages:{common:{close:"Cerrar",clear:"Borrar",open:"Abrir",remove:"Quitar",removeNamed:"Quitar {label}",loading:"Cargando"},textField:{showPassword:"Mostrar la contraseña",hidePassword:"Ocultar la contraseña"},empty:{title:"No hay nada aquí"},picker:{previousMonth:"Mes anterior",nextMonth:"Mes siguiente",previousYear:"Año anterior",nextYear:"Año siguiente",previousYears:"Años anteriores",nextYears:"Años siguientes",chooseMonth:"Elegir un mes",chooseYear:"Elegir un año",today:"Hoy",now:"Ahora",clear:"Borrar",done:"Listo",hour:"Hora",minute:"Minuto",second:"Segundo",meridiem:"a. m./p. m.",start:"Inicio",end:"Fin"},alert:{dismiss:"Cerrar"},chat:{sending:"Enviando",sent:"Enviado",delivered:"Entregado",read:"Leído",failed:"No enviado",typing:"Escribiendo"},spoiler:{reveal:"Mostrar",hide:"Ocultar",notice:"Oculto para que no se lea por accidente"},pagination:{label:"Paginación",page:"Página {page}",status:"Página {page} de {total}",previous:"Página anterior",next:"Página siguiente",first:"Primera página",last:"Última página"},rating:{label:"Valoración",value:"{value} de {max}",empty:"Sin valorar"}}};
@@ -0,0 +1,17 @@
1
+ /**
2
+ * French — Français.
3
+ *
4
+ * One of the tables `material-plus-ui/locales` holds. Nothing in the library
5
+ * imports it: a translation reaches a component only once the application has
6
+ * handed it over, which is what keeps eighteen languages out of a bundle that
7
+ * needs one. See `internal/i18n.ts` for the whole of that reasoning.
8
+ *
9
+ * import { registerMPMessages } from 'material-plus-ui';
10
+ * import { fr } from 'material-plus-ui/locales/fr';
11
+ *
12
+ * registerMPMessages(fr);
13
+ *
14
+ * Anything this table leaves out falls back to English, a namespace at a time.
15
+ */
16
+ import type { MPLocale } from '../internal/i18n';
17
+ export declare const fr: MPLocale;
@@ -0,0 +1 @@
1
+ export const fr={locale:"fr",messages:{common:{close:"Fermer",clear:"Effacer",open:"Ouvrir",remove:"Supprimer",removeNamed:"Supprimer {label}",loading:"Chargement"},textField:{showPassword:"Afficher le mot de passe",hidePassword:"Masquer le mot de passe"},empty:{title:"Il n'y a rien ici"},picker:{previousMonth:"Mois précédent",nextMonth:"Mois suivant",previousYear:"Année précédente",nextYear:"Année suivante",previousYears:"Années précédentes",nextYears:"Années suivantes",chooseMonth:"Choisir un mois",chooseYear:"Choisir une année",today:"Aujourd'hui",now:"Maintenant",clear:"Effacer",done:"Terminé",hour:"Heure",minute:"Minute",second:"Seconde",meridiem:"AM/PM",start:"Début",end:"Fin"},alert:{dismiss:"Fermer"},chat:{sending:"Envoi en cours",sent:"Envoyé",delivered:"Distribué",read:"Lu",failed:"Non envoyé",typing:"En train d'écrire"},spoiler:{reveal:"Afficher",hide:"Masquer",notice:"Masqué pour ne pas être lu par accident"},pagination:{label:"Pagination",page:"Page {page}",status:"Page {page} sur {total}",previous:"Page précédente",next:"Page suivante",first:"Première page",last:"Dernière page"},rating:{label:"Note",value:"{value} sur {max}",empty:"Non noté"}}};
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Hindi — हिन्दी.
3
+ *
4
+ * One of the tables `material-plus-ui/locales` holds. Nothing in the library
5
+ * imports it: a translation reaches a component only once the application has
6
+ * handed it over, which is what keeps eighteen languages out of a bundle that
7
+ * needs one. See `internal/i18n.ts` for the whole of that reasoning.
8
+ *
9
+ * import { registerMPMessages } from 'material-plus-ui';
10
+ * import { hi } from 'material-plus-ui/locales/hi';
11
+ *
12
+ * registerMPMessages(hi);
13
+ *
14
+ * Anything this table leaves out falls back to English, a namespace at a time.
15
+ */
16
+ import type { MPLocale } from '../internal/i18n';
17
+ export declare const hi: MPLocale;
@@ -0,0 +1 @@
1
+ export const hi={locale:"hi",messages:{common:{close:"बंद करें",clear:"हटाएँ",open:"खोलें",remove:"निकालें",removeNamed:"{label} निकालें",loading:"लोड हो रहा है"},textField:{showPassword:"पासवर्ड दिखाएँ",hidePassword:"पासवर्ड छिपाएँ"},empty:{title:"यहाँ कुछ नहीं है"},picker:{previousMonth:"पिछला महीना",nextMonth:"अगला महीना",previousYear:"पिछला वर्ष",nextYear:"अगला वर्ष",previousYears:"पिछले वर्ष",nextYears:"अगले वर्ष",chooseMonth:"महीना चुनें",chooseYear:"वर्ष चुनें",today:"आज",now:"अभी",clear:"हटाएँ",done:"हो गया",hour:"घंटा",minute:"मिनट",second:"सेकंड",meridiem:"AM/PM",start:"प्रारंभ",end:"समाप्ति"},alert:{dismiss:"बंद करें"},chat:{sending:"भेजा जा रहा है",sent:"भेजा गया",delivered:"पहुँच गया",read:"पढ़ लिया गया",failed:"नहीं भेजा गया",typing:"टाइप कर रहे हैं"},spoiler:{reveal:"दिखाएँ",hide:"छिपाएँ",notice:"गलती से न पढ़ लिया जाए इसलिए छिपाया गया है"},pagination:{label:"पृष्ठ क्रमांकन",page:"पृष्ठ {page}",status:"{total} में से पृष्ठ {page}",previous:"पिछला पृष्ठ",next:"अगला पृष्ठ",first:"पहला पृष्ठ",last:"अंतिम पृष्ठ"},rating:{label:"रेटिंग",value:"{max} में से {value}",empty:"रेटिंग नहीं दी गई"}}};
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Indonesian — Bahasa Indonesia.
3
+ *
4
+ * One of the tables `material-plus-ui/locales` holds. Nothing in the library
5
+ * imports it: a translation reaches a component only once the application has
6
+ * handed it over, which is what keeps eighteen languages out of a bundle that
7
+ * needs one. See `internal/i18n.ts` for the whole of that reasoning.
8
+ *
9
+ * import { registerMPMessages } from 'material-plus-ui';
10
+ * import { id } from 'material-plus-ui/locales/id';
11
+ *
12
+ * registerMPMessages(id);
13
+ *
14
+ * Anything this table leaves out falls back to English, a namespace at a time.
15
+ */
16
+ import type { MPLocale } from '../internal/i18n';
17
+ export declare const id: MPLocale;
@@ -0,0 +1 @@
1
+ export const id={locale:"id",messages:{common:{close:"Tutup",clear:"Bersihkan",open:"Buka",remove:"Hapus",removeNamed:"Hapus {label}",loading:"Memuat"},textField:{showPassword:"Tampilkan kata sandi",hidePassword:"Sembunyikan kata sandi"},empty:{title:"Tidak ada apa-apa di sini"},picker:{previousMonth:"Bulan sebelumnya",nextMonth:"Bulan berikutnya",previousYear:"Tahun sebelumnya",nextYear:"Tahun berikutnya",previousYears:"Tahun-tahun sebelumnya",nextYears:"Tahun-tahun berikutnya",chooseMonth:"Pilih bulan",chooseYear:"Pilih tahun",today:"Hari ini",now:"Sekarang",clear:"Hapus",done:"Selesai",hour:"Jam",minute:"Menit",second:"Detik",meridiem:"AM/PM",start:"Mulai",end:"Akhir"},alert:{dismiss:"Tutup"},chat:{sending:"Mengirim",sent:"Terkirim",delivered:"Diterima",read:"Dibaca",failed:"Gagal terkirim",typing:"Sedang mengetik"},spoiler:{reveal:"Tampilkan",hide:"Sembunyikan",notice:"Disembunyikan agar tidak terbaca tanpa sengaja"},pagination:{label:"Penomoran halaman",page:"Halaman {page}",status:"Halaman {page} dari {total}",previous:"Halaman sebelumnya",next:"Halaman berikutnya",first:"Halaman pertama",last:"Halaman terakhir"},rating:{label:"Peringkat",value:"{value} dari {max}",empty:"Belum dinilai"}}};
@@ -0,0 +1,89 @@
1
+ /**
2
+ * Every translation the library ships, and none of them in your bundle until you
3
+ * say so.
4
+ *
5
+ * This is a data package and nothing more: no component reaches into it, and
6
+ * `material-plus-ui` itself never imports it. That is the whole point. A table
7
+ * a component imported would be a table every consumer paid for — eighteen
8
+ * languages' worth of strings so that a button in São Paulo could say
9
+ * *Carregando* — so the direction is reversed and the application hands the
10
+ * library the languages it actually speaks:
11
+ *
12
+ * import { registerMPMessages } from 'material-plus-ui';
13
+ * import { ko, ja } from 'material-plus-ui/locales';
14
+ *
15
+ * registerMPMessages(ko, ja);
16
+ *
17
+ * Call it once, before anything renders. From then on `locale="ko"` — on
18
+ * `MPLocaleProvider` or on a component — resolves exactly as it would have if
19
+ * the table had been built in, because it is the same table.
20
+ *
21
+ * ## What to import, and from where
22
+ *
23
+ * - `material-plus-ui/locales/ko` is one language and costs one language.
24
+ * - `material-plus-ui/locales` is the same modules behind a barrel. A named
25
+ * import from it costs the same as the deep path — the barrel exists so a
26
+ * line that wants three languages can be one line rather than three.
27
+ * - `LOCALES` is all eighteen as an array, for an application that would rather
28
+ * ship the lot than maintain a list. An array literal cannot be tree-shaken
29
+ * element by element, so importing it is the choice to carry all of them.
30
+ *
31
+ * ## The tables
32
+ *
33
+ * | Tag | Language |
34
+ * | --- | --- |
35
+ * | `ko` | Korean |
36
+ * | `ja` | Japanese |
37
+ * | `zh-hans` | Chinese (Simplified) |
38
+ * | `zh-hant` | Chinese (Traditional) |
39
+ * | `es` | Spanish |
40
+ * | `pt` | Portuguese |
41
+ * | `fr` | French |
42
+ * | `de` | German |
43
+ * | `it` | Italian |
44
+ * | `nl` | Dutch |
45
+ * | `pl` | Polish |
46
+ * | `ru` | Russian |
47
+ * | `tr` | Turkish |
48
+ * | `ar` | Arabic |
49
+ * | `hi` | Hindi |
50
+ * | `id` | Indonesian |
51
+ * | `vi` | Vietnamese |
52
+ * | `th` | Thai |
53
+ *
54
+ * Chinese is keyed by script rather than by region, because that is the axis the
55
+ * words differ on. `zh-TW` and `zh-HK` are aliases of `zh-hant`, and `zh`,
56
+ * `zh-CN`, `zh-MY` and `zh-SG` of `zh-hans`; each table carries its own aliases,
57
+ * so registering it registers those too.
58
+ *
59
+ * A language that is not here is not a dead end: `MPLocale` is a plain object,
60
+ * and `registerMPMessages({ locale: 'sv', messages: { ... } })` is as good as
61
+ * anything in this directory.
62
+ */
63
+ export { ko } from './ko';
64
+ export { ja } from './ja';
65
+ export { zhHans } from './zh-hans';
66
+ export { zhHant } from './zh-hant';
67
+ export { es } from './es';
68
+ export { pt } from './pt';
69
+ export { fr } from './fr';
70
+ export { de } from './de';
71
+ export { it } from './it';
72
+ export { nl } from './nl';
73
+ export { pl } from './pl';
74
+ export { ru } from './ru';
75
+ export { tr } from './tr';
76
+ export { ar } from './ar';
77
+ export { hi } from './hi';
78
+ export { id } from './id';
79
+ export { vi } from './vi';
80
+ export { th } from './th';
81
+ import type { MPLocale } from '../internal/i18n';
82
+ /**
83
+ * All eighteen tables, in one array.
84
+ *
85
+ * `registerMPMessages(...LOCALES)` is the one line that restores the behaviour
86
+ * of a library with its translations built in, and it costs what that costs —
87
+ * see the note above about why this is an array and not the default.
88
+ */
89
+ export declare const LOCALES: MPLocale[];
@@ -0,0 +1 @@
1
+ export{ko}from"./ko";export{ja}from"./ja";export{zhHans}from"./zh-hans";export{zhHant}from"./zh-hant";export{es}from"./es";export{pt}from"./pt";export{fr}from"./fr";export{de}from"./de";export{it}from"./it";export{nl}from"./nl";export{pl}from"./pl";export{ru}from"./ru";export{tr}from"./tr";export{ar}from"./ar";export{hi}from"./hi";export{id}from"./id";export{vi}from"./vi";export{th}from"./th";import{ko as r}from"./ko";import{ja as o}from"./ja";import{zhHans as m}from"./zh-hans";import{zhHant as t}from"./zh-hant";import{es as p}from"./es";import{pt as f}from"./pt";import{fr as i}from"./fr";import{de as e}from"./de";import{it as x}from"./it";import{nl as h}from"./nl";import{pl as a}from"./pl";import{ru as n}from"./ru";import{tr as s}from"./tr";import{ar as d}from"./ar";import{hi as l}from"./hi";import{id as z}from"./id";import{vi as j}from"./vi";import{th as k}from"./th";export const LOCALES=[r,o,m,t,p,f,i,e,x,h,a,n,s,d,l,z,j,k];
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Italian — Italiano.
3
+ *
4
+ * One of the tables `material-plus-ui/locales` holds. Nothing in the library
5
+ * imports it: a translation reaches a component only once the application has
6
+ * handed it over, which is what keeps eighteen languages out of a bundle that
7
+ * needs one. See `internal/i18n.ts` for the whole of that reasoning.
8
+ *
9
+ * import { registerMPMessages } from 'material-plus-ui';
10
+ * import { it } from 'material-plus-ui/locales/it';
11
+ *
12
+ * registerMPMessages(it);
13
+ *
14
+ * Anything this table leaves out falls back to English, a namespace at a time.
15
+ */
16
+ import type { MPLocale } from '../internal/i18n';
17
+ export declare const it: MPLocale;
@@ -0,0 +1 @@
1
+ export const it={locale:"it",messages:{common:{close:"Chiudi",clear:"Cancella",open:"Apri",remove:"Rimuovi",removeNamed:"Rimuovi {label}",loading:"Caricamento"},textField:{showPassword:"Mostra la password",hidePassword:"Nascondi la password"},empty:{title:"Non c'è nulla qui"},picker:{previousMonth:"Mese precedente",nextMonth:"Mese successivo",previousYear:"Anno precedente",nextYear:"Anno successivo",previousYears:"Anni precedenti",nextYears:"Anni successivi",chooseMonth:"Scegli un mese",chooseYear:"Scegli un anno",today:"Oggi",now:"Adesso",clear:"Cancella",done:"Fatto",hour:"Ora",minute:"Minuto",second:"Secondo",meridiem:"AM/PM",start:"Inizio",end:"Fine"},alert:{dismiss:"Chiudi"},chat:{sending:"Invio in corso",sent:"Inviato",delivered:"Consegnato",read:"Letto",failed:"Non inviato",typing:"Sta scrivendo"},spoiler:{reveal:"Mostra",hide:"Nascondi",notice:"Nascosto per non essere letto per sbaglio"},pagination:{label:"Impaginazione",page:"Pagina {page}",status:"Pagina {page} di {total}",previous:"Pagina precedente",next:"Pagina successiva",first:"Prima pagina",last:"Ultima pagina"},rating:{label:"Valutazione",value:"{value} su {max}",empty:"Non valutato"}}};
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Japanese — 日本語.
3
+ *
4
+ * One of the tables `material-plus-ui/locales` holds. Nothing in the library
5
+ * imports it: a translation reaches a component only once the application has
6
+ * handed it over, which is what keeps eighteen languages out of a bundle that
7
+ * needs one. See `internal/i18n.ts` for the whole of that reasoning.
8
+ *
9
+ * import { registerMPMessages } from 'material-plus-ui';
10
+ * import { ja } from 'material-plus-ui/locales/ja';
11
+ *
12
+ * registerMPMessages(ja);
13
+ *
14
+ * Anything this table leaves out falls back to English, a namespace at a time.
15
+ */
16
+ import type { MPLocale } from '../internal/i18n';
17
+ export declare const ja: MPLocale;
@@ -0,0 +1 @@
1
+ export const ja={locale:"ja",messages:{common:{close:"閉じる",clear:"クリア",open:"開く",remove:"削除",removeNamed:"{label} を削除",loading:"読み込み中"},textField:{showPassword:"パスワードを表示",hidePassword:"パスワードを非表示"},empty:{title:"何もありません"},picker:{previousMonth:"前の月",nextMonth:"次の月",previousYear:"前の年",nextYear:"次の年",previousYears:"前の年の一覧",nextYears:"次の年の一覧",chooseMonth:"月を選択",chooseYear:"年を選択",today:"今日",now:"現在",clear:"クリア",done:"完了",hour:"時",minute:"分",second:"秒",meridiem:"午前/午後",start:"開始",end:"終了"},alert:{dismiss:"閉じる"},chat:{sending:"送信中",sent:"送信済み",delivered:"配信済み",read:"既読",failed:"送信できませんでした",typing:"入力中"},spoiler:{reveal:"表示する",hide:"隠す",notice:"うっかり読まないように隠してあります"},pagination:{label:"ページ送り",page:"{page}ページ",status:"{total}ページ中{page}ページ",previous:"前のページ",next:"次のページ",first:"最初のページ",last:"最後のページ"},rating:{label:"評価",value:"{max}段階中{value}",empty:"未評価"}}};