mirror of
https://github.com/ant-design/ant-design.git
synced 2024-11-24 02:59:58 +08:00
1 line
31 KiB
JavaScript
1 line
31 KiB
JavaScript
|
(("undefined"!=typeof globalThis?globalThis:self).makoChunk_antd=("undefined"!=typeof globalThis?globalThis:self).makoChunk_antd||[]).push([["f6fd367e"],{f6fd367e:function(a,e,d){"use strict";d.d(e,"__esModule",{value:!0}),d.d(e,"texts",{enumerable:!0,get:function(){return t;}}),d("be3c4b82");let t=[{value:"By clicking the input box, you can select a date from a popup calendar.",paraId:0,tocIndex:0},{value:"Common props ref\uFF1A",paraId:1,tocIndex:31},{value:"Common props",paraId:2,tocIndex:31},{value:"There are five kinds of picker:",paraId:3,tocIndex:31},{value:"DatePicker",paraId:4,tocIndex:31},{value:'DatePicker[picker="month"]',paraId:4,tocIndex:31},{value:'DatePicker[picker="week"]',paraId:4,tocIndex:31},{value:'DatePicker[picker="year"]',paraId:4,tocIndex:31},{value:'DatePicker[picker="quarter"] (Added in 4.1.0)',paraId:4,tocIndex:31},{value:"RangePicker",paraId:4,tocIndex:31},{value:"The default locale is en-US, if you need to use other languages, recommend to use internationalized components provided by us at the entrance. Look at: ",paraId:5,tocIndex:32},{value:"ConfigProvider",paraId:5,tocIndex:32},{value:".",paraId:5,tocIndex:32},{value:"If there are special needs (only modifying single component language), Please use the property: local. Example: ",paraId:6,tocIndex:32},{value:"default",paraId:6,tocIndex:32},{value:".",paraId:6,tocIndex:32},{value:"// The default locale is en-US, if you want to use other locale, just set locale in entry file globally.\n// Make sure you import the relevant dayjs file as well, otherwise the locale won't change for all texts (e.g. range picker months)\nimport locale from 'antd/locale/zh_CN';\nimport dayjs from 'dayjs';\n\nimport 'dayjs/locale/zh-cn';\n\ndayjs.locale('zh-cn');\n\n<ConfigProvider locale={locale}>\n <DatePicker defaultValue={dayjs('2015-01-01', 'YYYY-MM-DD')} />\n</ConfigProvider>;\n",paraId:7,tocIndex:32},{value:"When use with Next.js App Router, make sure to add ",paraId:8},{value:"'use client'",paraId:8},{value:" before import locale file of dayjs. It's because all components of Ant Design only works in client, importing locale in RSC will not work.",paraId:8},{value:"The following APIs are shared by DatePicker, RangePicker.",paraId:9,tocIndex:33},{value:"Property",paraId:10,tocIndex:33},{value:"Description",paraId:10,tocIndex:33},{value:"Type",paraId:10,tocIndex:33},{value:"Default",paraId:10,tocIndex:33},{value:"Version",paraId:10,tocIndex:33},{value:"allowClear",paraId:10,tocIndex:33},{value:"Customize clear button",paraId:10,tocIndex:33},{value:"boolean | { clearIcon?: ReactNode }",paraId:10,tocIndex:33},{value:"true",paraId:10,tocIndex:33},{value:"5.8.0: Support object type",paraId:10,tocIndex:33},{value:"autoFocus",paraId:10,tocIndex:33},{value:"If get focus when component mounted",paraId:10,tocIndex:33},{value:"boolean",paraId:10,tocIndex:33},{value:"false",paraId:10,tocIndex:33},{value:"className",paraId:10,tocIndex:33},{value:"The picker className",paraId:10,tocIndex:33},{value:"string",paraId:10,tocIndex:33},{value:"-",paraId:10,tocIndex:33},{value:"dateRender",paraId:10,tocIndex:33},{value:"Custom rendering function for date cells, >= 5.4.0 use ",paraId:10,tocIndex:33},{value:"cellRender",paraId:10,tocIndex:33},{value:" instead.",paraId:10,tocIndex:33},{value:"function(currentDate: dayjs, today: dayjs) => React.ReactNode",paraId:10,tocIndex:33},{value:"-",paraId:10,tocIndex:33},{value:"< 5.4.0",paraId:10,tocIndex:33},{value:"cellRender",paraId:10,tocIndex:33},{value:"Custom rendering function for picker cells",paraId:10,tocIndex:33},{value:"(current: dayjs, info: { originNode: React.ReactElement,today: DateType, range?: 'start' | 'end', type: PanelMode, locale?: Locale, subType?: 'hour' | 'minute' | 'second' | 'meridiem' }) => React.ReactNode",paraId:10,tocIndex:33},{value:"-",paraId:10,tocIndex:33},{value:"5.4.0",paraId:10,tocIndex:33},{value:"components",paraId:10,tocIndex:33},{value:"Custom panels",paraId:10,tocIndex:33},{value:"Record<Panel | 'input', React.ComponentType>",paraId:10,tocIndex:33},{value:"-",paraId:10,tocIndex:33},{value:"5.14.0
|