minerva-design 1.0.0 → 1.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +12 -0
- package/custom-elements.json +663 -0
- package/dist/angular/fesm2022/minerva-angular.mjs +1163 -34
- package/dist/angular/fesm2022/minerva-angular.mjs.map +1 -1
- package/dist/angular/types/minerva-angular.d.ts +237 -1
- package/dist/core/calendar-date.d.cts +5 -0
- package/dist/core/calendar-date.d.ts +5 -0
- package/dist/core/contracts.cjs +1 -1
- package/dist/core/contracts.cjs.map +1 -1
- package/dist/core/contracts.js +1 -1
- package/dist/core/contracts.js.map +1 -1
- package/dist/core/index.cjs +6 -6
- package/dist/core/index.cjs.map +1 -1
- package/dist/core/index.js +671 -630
- package/dist/core/index.js.map +1 -1
- package/dist/core/styling-hooks/components/date-picker.d.cts +45 -0
- package/dist/core/styling-hooks/components/date-picker.d.ts +45 -0
- package/dist/core/styling-hooks/manifest.d.cts +44 -0
- package/dist/core/styling-hooks/manifest.d.ts +44 -0
- package/dist/core/styling-hooks.cjs +1 -1
- package/dist/core/styling-hooks.cjs.map +1 -1
- package/dist/core/styling-hooks.js +62 -0
- package/dist/core/styling-hooks.js.map +1 -1
- package/dist/native/components/Calendar/Calendar.cjs +1 -1
- package/dist/native/components/Calendar/Calendar.cjs.map +1 -1
- package/dist/native/components/Calendar/Calendar.d.cts +2 -0
- package/dist/native/components/Calendar/Calendar.d.ts +2 -0
- package/dist/native/components/Calendar/Calendar.js +115 -112
- package/dist/native/components/Calendar/Calendar.js.map +1 -1
- package/dist/native/components/Checkbox/Checkbox.cjs +1 -1
- package/dist/native/components/Checkbox/Checkbox.cjs.map +1 -1
- package/dist/native/components/Checkbox/Checkbox.js +8 -8
- package/dist/native/components/Checkbox/CheckboxGroup.cjs +1 -1
- package/dist/native/components/Checkbox/CheckboxGroup.cjs.map +1 -1
- package/dist/native/components/Checkbox/CheckboxGroup.js +6 -6
- package/dist/native/components/DatePicker/DatePicker.cjs +2 -0
- package/dist/native/components/DatePicker/DatePicker.cjs.map +1 -0
- package/dist/native/components/DatePicker/DatePicker.d.cts +40 -0
- package/dist/native/components/DatePicker/DatePicker.d.ts +40 -0
- package/dist/native/components/DatePicker/DatePicker.js +110 -0
- package/dist/native/components/DatePicker/DatePicker.js.map +1 -0
- package/dist/native/components/DatePicker/index.cjs +1 -0
- package/dist/native/components/DatePicker/index.d.cts +2 -0
- package/dist/native/components/DatePicker/index.d.ts +2 -0
- package/dist/native/components/DatePicker/index.js +2 -0
- package/dist/native/components/Radio/RadioGroup.cjs +1 -1
- package/dist/native/components/Radio/RadioGroup.cjs.map +1 -1
- package/dist/native/components/Radio/RadioGroup.js +9 -9
- package/dist/native/components/Switch/Switch.cjs +1 -1
- package/dist/native/components/Switch/Switch.cjs.map +1 -1
- package/dist/native/components/Switch/Switch.js +23 -23
- package/dist/native/components/Switch/Switch.js.map +1 -1
- package/dist/native/index.cjs +1 -1
- package/dist/native/index.d.cts +1 -0
- package/dist/native/index.d.ts +1 -0
- package/dist/native/index.js +70 -68
- package/dist/native/source/components/Calendar/Calendar.tsx +14 -6
- package/dist/native/source/components/DatePicker/DatePicker.tsx +201 -0
- package/dist/native/source/components/DatePicker/index.ts +2 -0
- package/dist/native/source/index.ts +1 -0
- package/dist/native/source/manifest.ts +6 -0
- package/dist/react/components/DatePicker/DatePicker.cjs +2 -0
- package/dist/react/components/DatePicker/DatePicker.cjs.map +1 -0
- package/dist/react/components/DatePicker/DatePicker.d.cts +13 -0
- package/dist/react/components/DatePicker/DatePicker.d.ts +13 -0
- package/dist/react/components/DatePicker/DatePicker.js +315 -0
- package/dist/react/components/DatePicker/DatePicker.js.map +1 -0
- package/dist/react/components/DatePicker/datePicker.module.scss.cjs +2 -0
- package/dist/react/components/DatePicker/datePicker.module.scss.cjs.map +1 -0
- package/dist/react/components/DatePicker/datePicker.module.scss.js +23 -0
- package/dist/react/components/DatePicker/datePicker.module.scss.js.map +1 -0
- package/dist/react/components/DatePicker/index.cjs +1 -0
- package/dist/react/components/DatePicker/index.d.cts +5 -0
- package/dist/react/components/DatePicker/index.d.ts +5 -0
- package/dist/react/components/DatePicker/index.js +3 -0
- package/dist/react/components/DatePicker/types.d.cts +97 -0
- package/dist/react/components/DatePicker/types.d.ts +97 -0
- package/dist/react/components/Tooltip/Tooltip.cjs +1 -1
- package/dist/react/components/Tooltip/Tooltip.cjs.map +1 -1
- package/dist/react/components/Tooltip/Tooltip.js +5 -5
- package/dist/react/components/Tooltip/Tooltip.js.map +1 -1
- package/dist/react/components/index.cjs +1 -1
- package/dist/react/components/index.d.cts +1 -0
- package/dist/react/components/index.d.ts +1 -0
- package/dist/react/components/index.js +3 -1
- package/dist/react/index.cjs +1 -1
- package/dist/react/index.js +7 -6
- package/dist/react/style.css +1 -0
- package/dist/react/styles/date-picker.css +7 -0
- package/dist/taro/date-picker.d.ts +20 -0
- package/dist/taro/index.d.ts +1 -0
- package/dist/taro/index.js +1155 -990
- package/dist/uni/DatePicker.vue +225 -0
- package/dist/uni/DatePicker.vue.d.ts +36 -0
- package/dist/uni/MonthCalendar.vue +2 -0
- package/dist/uni/MonthCalendar.vue.d.ts +2 -0
- package/dist/uni/index.d.ts +1 -0
- package/dist/uni/index.js +1 -0
- package/dist/uni/manifest.d.ts +7 -0
- package/dist/uni/manifest.js +8 -0
- package/dist/vue/components/DatePicker/DatePicker.vue.d.ts +36 -0
- package/dist/vue/components/DatePicker/DatePicker.vue.js +7 -0
- package/dist/vue/components/DatePicker/DatePicker.vue.js.map +1 -0
- package/dist/vue/components/DatePicker/DatePicker.vue_vue_type_script_setup_true_lang.js +380 -0
- package/dist/vue/components/DatePicker/DatePicker.vue_vue_type_script_setup_true_lang.js.map +1 -0
- package/dist/vue/components/DatePicker/index.d.ts +2 -0
- package/dist/vue/components/DatePicker/index.js +2 -0
- package/dist/vue/components/DatePicker/types.d.ts +26 -0
- package/dist/vue/components/MonthCalendar/MonthCalendar.vue.d.ts +1 -1
- package/dist/vue/global.d.ts +108 -0
- package/dist/vue/groups/forms-pickers.d.ts +1 -0
- package/dist/vue/groups/forms-pickers.js +5 -2
- package/dist/vue/groups/forms-pickers.js.map +1 -1
- package/dist/vue/index.js +95 -94
- package/dist/weapp/controls.js +259 -76
- package/dist/weapp/date-picker/index.js +1 -0
- package/dist/weapp/date-picker/index.json +1 -0
- package/dist/weapp/date-picker/index.wxml +1 -0
- package/dist/weapp/date-picker/index.wxss +1 -0
- package/dist/weapp/types.d.ts +19 -0
- package/dist/web-components/cdn/minerva.js +461 -335
- package/dist/web-components/cdn/minerva.js.map +1 -1
- package/dist/web-components/components/date-picker/date-picker.d.ts +110 -0
- package/dist/web-components/components/date-picker/date-picker.js +378 -0
- package/dist/web-components/components/date-picker/date-picker.js.map +1 -0
- package/dist/web-components/elements/date-picker.d.ts +1 -0
- package/dist/web-components/elements/date-picker.js +8 -0
- package/dist/web-components/elements/date-picker.js.map +1 -0
- package/dist/web-components/html-custom-data.json +85 -0
- package/dist/web-components/index.d.ts +1 -0
- package/dist/web-components/index.js +8 -6
- package/dist/web-components/styles/DatePicker/datePicker.css.js +6 -0
- package/dist/web-components/styles/DatePicker/datePicker.css.js.map +1 -0
- package/dist/web-components/types/react.d.ts +12 -0
- package/dist/web-components/types/solid.d.ts +9 -0
- package/dist/web-components/types/svelte.d.ts +9 -0
- package/dist/web-components/types/vue.d.ts +10 -0
- package/package.json +9 -1
package/dist/vue/index.js
CHANGED
|
@@ -39,103 +39,104 @@ import I from "./components/JsonField/JsonField.vue.js";
|
|
|
39
39
|
import L from "./components/Tag/Tag.vue.js";
|
|
40
40
|
import R from "./components/TagInput/TagInput.vue.js";
|
|
41
41
|
import z from "./components/Cascader/Cascader.vue.js";
|
|
42
|
+
import B from "./components/DatePicker/DatePicker.vue.js";
|
|
42
43
|
import "./groups/forms-pickers.js";
|
|
43
|
-
import
|
|
44
|
-
import
|
|
45
|
-
import
|
|
46
|
-
import
|
|
47
|
-
import
|
|
48
|
-
import
|
|
49
|
-
import
|
|
50
|
-
import
|
|
51
|
-
import
|
|
52
|
-
import
|
|
53
|
-
import
|
|
54
|
-
import
|
|
55
|
-
import
|
|
56
|
-
import
|
|
57
|
-
import
|
|
58
|
-
import
|
|
59
|
-
import
|
|
60
|
-
import { confirm as
|
|
61
|
-
import
|
|
62
|
-
import
|
|
63
|
-
import { matchesShortcut as
|
|
64
|
-
import { toast as
|
|
65
|
-
import
|
|
66
|
-
import { useToast as
|
|
67
|
-
import
|
|
68
|
-
import
|
|
69
|
-
import
|
|
70
|
-
import
|
|
71
|
-
import
|
|
72
|
-
import
|
|
73
|
-
import
|
|
74
|
-
import
|
|
44
|
+
import V from "./components/Modal/ModalRoot.vue.js";
|
|
45
|
+
import H from "./components/Modal/ModalTrigger.vue.js";
|
|
46
|
+
import U from "./components/Modal/ModalContent.vue.js";
|
|
47
|
+
import W from "./components/Modal/ModalHeader.vue.js";
|
|
48
|
+
import G from "./components/Modal/Modal.vue.js";
|
|
49
|
+
import K from "./components/Modal/ModalClose.vue.js";
|
|
50
|
+
import q from "./components/Modal/ModalBody.vue.js";
|
|
51
|
+
import J from "./components/Modal/ModalFooter.vue.js";
|
|
52
|
+
import Y from "./components/Drawer/DrawerRoot.vue.js";
|
|
53
|
+
import X from "./components/Drawer/DrawerTrigger.vue.js";
|
|
54
|
+
import Z from "./components/Drawer/DrawerContent.vue.js";
|
|
55
|
+
import re from "./components/Drawer/DrawerHeader.vue.js";
|
|
56
|
+
import ie from "./components/Drawer/Drawer.vue.js";
|
|
57
|
+
import ae from "./components/Drawer/DrawerClose.vue.js";
|
|
58
|
+
import oe from "./components/Drawer/DrawerBody.vue.js";
|
|
59
|
+
import se from "./components/Drawer/DrawerFooter.vue.js";
|
|
60
|
+
import ce from "./components/Confirm/ConfirmDialog.vue.js";
|
|
61
|
+
import { confirm as le, useConfirm as ue } from "./components/Confirm/confirm.js";
|
|
62
|
+
import de from "./components/Confirm/ConfirmProvider.vue.js";
|
|
63
|
+
import fe from "./components/Command/CommandDialog.vue.js";
|
|
64
|
+
import { matchesShortcut as pe, normalizeShortcuts as me } from "./components/Command/index.js";
|
|
65
|
+
import { toast as he } from "./components/Toast/store.js";
|
|
66
|
+
import ge from "./components/Toast/ToastProvider.vue.js";
|
|
67
|
+
import { useToast as _e } from "./components/Toast/useToast.js";
|
|
68
|
+
import ve from "./components/Popover/Popover.vue.js";
|
|
69
|
+
import ye from "./components/Popover/PopoverTrigger.vue.js";
|
|
70
|
+
import be from "./components/Popover/PopoverAnchor.vue.js";
|
|
71
|
+
import xe from "./components/Popover/PopoverClose.vue.js";
|
|
72
|
+
import Se from "./components/Popover/PopoverContent.vue.js";
|
|
73
|
+
import Ce from "./components/Tooltip/TooltipProvider.vue.js";
|
|
74
|
+
import we from "./components/Menu/Menu.vue.js";
|
|
75
|
+
import Te from "./components/Menu/ContextMenu.vue.js";
|
|
75
76
|
import "./groups/overlays.js";
|
|
76
|
-
import
|
|
77
|
-
import
|
|
78
|
-
import
|
|
79
|
-
import
|
|
80
|
-
import
|
|
81
|
-
import
|
|
82
|
-
import
|
|
83
|
-
import
|
|
84
|
-
import
|
|
85
|
-
import
|
|
86
|
-
import
|
|
87
|
-
import
|
|
88
|
-
import
|
|
89
|
-
import
|
|
90
|
-
import { computeFixedColumnLayout as
|
|
91
|
-
import
|
|
92
|
-
import
|
|
93
|
-
import
|
|
94
|
-
import
|
|
95
|
-
import
|
|
96
|
-
import
|
|
77
|
+
import Ee from "./components/Tabs/Tabs.vue.js";
|
|
78
|
+
import De from "./components/Tabs/TabList.vue.js";
|
|
79
|
+
import Q from "./components/Tabs/Tab.vue.js";
|
|
80
|
+
import Oe from "./components/Tabs/TabPanel.vue.js";
|
|
81
|
+
import ke from "./components/Pagination/Pagination.vue.js";
|
|
82
|
+
import Ae from "./components/VirtualList/VirtualList.vue.js";
|
|
83
|
+
import je from "./components/MonthCalendar/MonthCalendar.vue.js";
|
|
84
|
+
import Me from "./components/Steps/Steps.vue.js";
|
|
85
|
+
import Ne from "./components/Table/TableRoot.vue.js";
|
|
86
|
+
import Pe from "./components/Table/TableHead.vue.js";
|
|
87
|
+
import Fe from "./components/Table/TableBody.vue.js";
|
|
88
|
+
import Ie from "./components/Table/TableRow.vue.js";
|
|
89
|
+
import Le from "./components/Table/TableHeader.vue.js";
|
|
90
|
+
import Re from "./components/Table/TableCell.vue.js";
|
|
91
|
+
import { computeFixedColumnLayout as ze } from "./components/Table/fixedColumns.js";
|
|
92
|
+
import Be from "./components/Table/Table.vue.js";
|
|
93
|
+
import Ve from "./components/Table/DataTable.vue.js";
|
|
94
|
+
import He from "./components/Table/TableCellContent.vue.js";
|
|
95
|
+
import Ue from "./components/NavTree/NavTree.vue.js";
|
|
96
|
+
import We from "./components/PageTabs/PageTabs.vue.js";
|
|
97
|
+
import Ge from "./components/PageTabs/PageTab.vue.js";
|
|
97
98
|
import "./groups/navigation.js";
|
|
98
|
-
import
|
|
99
|
-
import
|
|
100
|
-
import
|
|
101
|
-
import
|
|
102
|
-
import
|
|
103
|
-
import
|
|
104
|
-
import
|
|
105
|
-
import
|
|
106
|
-
import
|
|
107
|
-
import
|
|
108
|
-
import
|
|
109
|
-
import
|
|
110
|
-
import
|
|
111
|
-
import
|
|
112
|
-
import
|
|
113
|
-
import
|
|
114
|
-
import
|
|
115
|
-
import
|
|
116
|
-
import
|
|
117
|
-
import
|
|
118
|
-
import
|
|
119
|
-
import
|
|
120
|
-
import
|
|
121
|
-
import
|
|
122
|
-
import
|
|
123
|
-
import
|
|
124
|
-
import
|
|
125
|
-
import
|
|
126
|
-
import
|
|
127
|
-
import
|
|
128
|
-
import { useConfig as
|
|
129
|
-
import { useTheme as
|
|
130
|
-
import
|
|
131
|
-
import
|
|
132
|
-
import
|
|
99
|
+
import Ke from "./components/Box/Box.vue.js";
|
|
100
|
+
import qe from "./components/Stack/Stack.vue.js";
|
|
101
|
+
import Je from "./components/Stack/HStack.vue.js";
|
|
102
|
+
import Ye from "./components/Stack/VStack.vue.js";
|
|
103
|
+
import Xe from "./components/SplitLayout/SplitLayout.vue.js";
|
|
104
|
+
import Ze from "./components/Page/Page.vue.js";
|
|
105
|
+
import Qe from "./components/Page/PageHeader.vue.js";
|
|
106
|
+
import $e from "./components/Page/PageSection.vue.js";
|
|
107
|
+
import et from "./components/Page/Toolbar.vue.js";
|
|
108
|
+
import tt from "./components/Page/StatCard.vue.js";
|
|
109
|
+
import nt from "./components/Card/Card.vue.js";
|
|
110
|
+
import rt from "./components/Card/CardHeader.vue.js";
|
|
111
|
+
import it from "./components/Card/CardTitle.vue.js";
|
|
112
|
+
import at from "./components/Card/CardDescription.vue.js";
|
|
113
|
+
import ot from "./components/Card/CardContent.vue.js";
|
|
114
|
+
import st from "./components/Card/CardFooter.vue.js";
|
|
115
|
+
import ct from "./components/Badge/Badge.vue.js";
|
|
116
|
+
import lt from "./components/Avatar/Avatar.vue.js";
|
|
117
|
+
import ut from "./components/Avatar/AvatarGroup.vue.js";
|
|
118
|
+
import dt from "./components/Divider/Divider.vue.js";
|
|
119
|
+
import ft from "./components/Skeleton/Skeleton.vue.js";
|
|
120
|
+
import pt from "./components/Skeleton/SkeletonText.vue.js";
|
|
121
|
+
import mt from "./components/LoadingState/LoadingState.vue.js";
|
|
122
|
+
import ht from "./components/List/List.vue.js";
|
|
123
|
+
import gt from "./components/List/ListItem.vue.js";
|
|
124
|
+
import _t from "./components/DescriptionList/DescriptionList.vue.js";
|
|
125
|
+
import vt from "./components/CodeBlock/CodeBlock.vue.js";
|
|
126
|
+
import yt from "./components/Prose/Prose.vue.js";
|
|
127
|
+
import bt from "./components/HtmlPreview/HtmlPreview.vue.js";
|
|
128
|
+
import xt from "./components/TextLink/TextLink.vue.js";
|
|
129
|
+
import { useConfig as St } from "./config/context.js";
|
|
130
|
+
import { useTheme as Ct } from "./config/useTheme.js";
|
|
131
|
+
import wt from "./components/ThemeToggle/ThemeToggle.vue.js";
|
|
132
|
+
import Tt from "./components/ThemeToggle/PaletteToggle.vue.js";
|
|
133
|
+
import Et from "./components/AppShell/AppShell.vue.js";
|
|
133
134
|
import "./groups/display.js";
|
|
134
|
-
import
|
|
135
|
-
import
|
|
136
|
-
import { useLocale as
|
|
137
|
-
import { provideEmbeddedScope as
|
|
135
|
+
import Dt from "./config/ConfigProvider.vue.js";
|
|
136
|
+
import Ot from "./config/ThemeProvider.vue.js";
|
|
137
|
+
import { useLocale as kt } from "./config/useLocale.js";
|
|
138
|
+
import { provideEmbeddedScope as At } from "./config/embed.js";
|
|
138
139
|
import "./groups/config.js";
|
|
139
140
|
import { MinervaVue as $ } from "./plugin.js";
|
|
140
|
-
import { cn as
|
|
141
|
-
export { N as Alert,
|
|
141
|
+
import { cn as jt, dark as Mt, githubDark as Nt, light as Pt, palettes as Ft, themes as It } from "../core/index.js";
|
|
142
|
+
export { N as Alert, Et as AppShell, j as AutoComplete, lt as Avatar, ut as AvatarGroup, ct as Badge, Ke as Box, ee as Button, nt as Card, ot as CardContent, at as CardDescription, st as CardFooter, rt as CardHeader, it as CardTitle, z as Cascader, g as Checkbox, vt as CodeBlock, fe as CommandDialog, Dt as ConfigProvider, ce as ConfirmDialog, de as ConfirmProvider, Te as ContextMenu, Ve as DataTable, B as DatePicker, _t as DescriptionList, dt as Divider, ie as Drawer, oe as DrawerBody, ae as DrawerClose, Z as DrawerContent, se as DrawerFooter, re as DrawerHeader, Y as DrawerRoot, X as DrawerTrigger, k as Empty, te as FORM_CONTROL_KEY, t as FormControl, i as FormErrorMessage, a as FormField, r as FormHelperText, n as FormLabel, c as FormLayout, s as GridItem, Je as HStack, bt as HtmlPreview, x as IconButton, p as Input, I as JsonField, M as KeyValueEditor, ht as List, gt as ListItem, mt as LoadingState, we as Menu, $ as MinervaVue, G as Modal, q as ModalBody, K as ModalClose, U as ModalContent, J as ModalFooter, W as ModalHeader, V as ModalRoot, H as ModalTrigger, je as MonthCalendar, Ue as NavTree, h as NumberInput, Ze as Page, Qe as PageHeader, $e as PageSection, Ge as PageTab, We as PageTabs, ke as Pagination, Tt as PaletteToggle, ve as Popover, be as PopoverAnchor, xe as PopoverClose, Se as PopoverContent, ye as PopoverTrigger, A as ProgressIndicator, yt as Prose, _ as Radio, v as RadioGroup, S as Rating, C as RatingScale, o as ResponsiveGrid, T as Select, E as SelectGroup, w as SelectItem, D as SelectLabel, O as SelectSeparator, ft as Skeleton, pt as SkeletonText, Xe as SplitLayout, qe as Stack, tt as StatCard, Me as Steps, y as Switch, Q as Tab, De as TabList, Oe as TabPanel, Be as Table, Fe as TableBody, Re as TableCell, He as TableCellContent, Pe as TableHead, Le as TableHeader, Ne as TableRoot, Ie as TableRow, Ee as Tabs, L as Tag, R as TagInput, xt as TextLink, m as Textarea, Ot as ThemeProvider, wt as ThemeToggle, F as TimePicker, ge as ToastProvider, et as Toolbar, b as Tooltip, Ce as TooltipProvider, P as Upload, Ye as VStack, Ae as VirtualList, jt as cn, ze as computeFixedColumnLayout, le as confirm, Mt as dark, $ as default, l as getLanguage, Nt as githubDark, Pt as light, pe as matchesShortcut, me as normalizeShortcuts, Ft as palettes, At as provideEmbeddedScope, u as setLanguage, It as themes, he as toast, d as translateMessage, St as useConfig, ue as useConfirm, ne as useFormControlContext, e as useFormControlProps, f as useI18n, kt as useLocale, Ct as useTheme, _e as useToast };
|
package/dist/weapp/controls.js
CHANGED
|
@@ -2383,25 +2383,33 @@ var general_default$3 = {
|
|
|
2383
2383
|
"remove": "Remove {{name}}"
|
|
2384
2384
|
}
|
|
2385
2385
|
};
|
|
2386
|
-
var inputs_default$3 = {
|
|
2387
|
-
|
|
2388
|
-
|
|
2389
|
-
|
|
2390
|
-
|
|
2391
|
-
|
|
2392
|
-
"
|
|
2393
|
-
|
|
2394
|
-
|
|
2395
|
-
|
|
2396
|
-
|
|
2397
|
-
|
|
2398
|
-
|
|
2399
|
-
|
|
2400
|
-
|
|
2401
|
-
|
|
2402
|
-
|
|
2403
|
-
|
|
2404
|
-
|
|
2386
|
+
var inputs_default$3 = {
|
|
2387
|
+
monthCalendar: {
|
|
2388
|
+
"label": "Month calendar",
|
|
2389
|
+
"previousMonth": "Previous month",
|
|
2390
|
+
"nextMonth": "Next month",
|
|
2391
|
+
"today": "Today",
|
|
2392
|
+
"weekdays": {
|
|
2393
|
+
"mon": "Mon",
|
|
2394
|
+
"tue": "Tue",
|
|
2395
|
+
"wed": "Wed",
|
|
2396
|
+
"thu": "Thu",
|
|
2397
|
+
"fri": "Fri",
|
|
2398
|
+
"sat": "Sat",
|
|
2399
|
+
"sun": "Sun"
|
|
2400
|
+
},
|
|
2401
|
+
"dayWithEvents_one": "{{date}}, {{count}} event",
|
|
2402
|
+
"dayWithEvents_other": "{{date}}, {{count}} events",
|
|
2403
|
+
"eventsLabel": "Events on {{date}}",
|
|
2404
|
+
"noEvents": "No events"
|
|
2405
|
+
},
|
|
2406
|
+
datePicker: {
|
|
2407
|
+
"placeholder": "Select date",
|
|
2408
|
+
"label": "Date",
|
|
2409
|
+
"clear": "Clear date",
|
|
2410
|
+
"today": "Today"
|
|
2411
|
+
}
|
|
2412
|
+
};
|
|
2405
2413
|
var layout_default$3 = { appShell: {
|
|
2406
2414
|
"navigation": "Navigation",
|
|
2407
2415
|
"expand": "Expand sidebar",
|
|
@@ -2686,25 +2694,33 @@ var messages$3 = /* @__PURE__ */ mergeMessages({
|
|
|
2686
2694
|
"retry": "Réessayer {{name}}",
|
|
2687
2695
|
"remove": "Retirer {{name}}"
|
|
2688
2696
|
}
|
|
2689
|
-
}, {
|
|
2690
|
-
|
|
2691
|
-
|
|
2692
|
-
|
|
2693
|
-
|
|
2694
|
-
|
|
2695
|
-
"
|
|
2696
|
-
|
|
2697
|
-
|
|
2698
|
-
|
|
2699
|
-
|
|
2700
|
-
|
|
2701
|
-
|
|
2702
|
-
|
|
2703
|
-
|
|
2704
|
-
|
|
2705
|
-
|
|
2706
|
-
|
|
2707
|
-
|
|
2697
|
+
}, {
|
|
2698
|
+
monthCalendar: {
|
|
2699
|
+
"label": "Calendrier mensuel",
|
|
2700
|
+
"previousMonth": "Mois précédent",
|
|
2701
|
+
"nextMonth": "Mois suivant",
|
|
2702
|
+
"today": "Aujourd’hui",
|
|
2703
|
+
"weekdays": {
|
|
2704
|
+
"mon": "lun.",
|
|
2705
|
+
"tue": "mar.",
|
|
2706
|
+
"wed": "mer.",
|
|
2707
|
+
"thu": "jeu.",
|
|
2708
|
+
"fri": "ven.",
|
|
2709
|
+
"sat": "sam.",
|
|
2710
|
+
"sun": "dim."
|
|
2711
|
+
},
|
|
2712
|
+
"dayWithEvents_one": "{{date}}, {{count}} événement",
|
|
2713
|
+
"dayWithEvents_other": "{{date}}, {{count}} événements",
|
|
2714
|
+
"eventsLabel": "Événements du {{date}}",
|
|
2715
|
+
"noEvents": "Aucun événement"
|
|
2716
|
+
},
|
|
2717
|
+
datePicker: {
|
|
2718
|
+
"placeholder": "Choisir une date",
|
|
2719
|
+
"label": "Date",
|
|
2720
|
+
"clear": "Effacer la date",
|
|
2721
|
+
"today": "Aujourd’hui"
|
|
2722
|
+
}
|
|
2723
|
+
}, { appShell: {
|
|
2708
2724
|
"navigation": "Navigation",
|
|
2709
2725
|
"expand": "Déplier la barre latérale",
|
|
2710
2726
|
"collapse": "Replier la barre latérale",
|
|
@@ -2970,25 +2986,33 @@ var messages$2 = /* @__PURE__ */ mergeMessages({
|
|
|
2970
2986
|
"retry": "{{name}} を再試行",
|
|
2971
2987
|
"remove": "{{name}} を削除"
|
|
2972
2988
|
}
|
|
2973
|
-
}, {
|
|
2974
|
-
|
|
2975
|
-
|
|
2976
|
-
|
|
2977
|
-
|
|
2978
|
-
|
|
2979
|
-
"
|
|
2980
|
-
|
|
2981
|
-
|
|
2982
|
-
|
|
2983
|
-
|
|
2984
|
-
|
|
2985
|
-
|
|
2986
|
-
|
|
2987
|
-
|
|
2988
|
-
|
|
2989
|
-
|
|
2990
|
-
|
|
2991
|
-
|
|
2989
|
+
}, {
|
|
2990
|
+
monthCalendar: {
|
|
2991
|
+
"label": "月間カレンダー",
|
|
2992
|
+
"previousMonth": "前の月",
|
|
2993
|
+
"nextMonth": "次の月",
|
|
2994
|
+
"today": "今日",
|
|
2995
|
+
"weekdays": {
|
|
2996
|
+
"mon": "月",
|
|
2997
|
+
"tue": "火",
|
|
2998
|
+
"wed": "水",
|
|
2999
|
+
"thu": "木",
|
|
3000
|
+
"fri": "金",
|
|
3001
|
+
"sat": "土",
|
|
3002
|
+
"sun": "日"
|
|
3003
|
+
},
|
|
3004
|
+
"dayWithEvents_one": "{{date}}、予定 {{count}} 件",
|
|
3005
|
+
"dayWithEvents_other": "{{date}}、予定 {{count}} 件",
|
|
3006
|
+
"eventsLabel": "{{date}} の予定",
|
|
3007
|
+
"noEvents": "予定はありません"
|
|
3008
|
+
},
|
|
3009
|
+
datePicker: {
|
|
3010
|
+
"placeholder": "日付を選択",
|
|
3011
|
+
"label": "日付",
|
|
3012
|
+
"clear": "日付をクリア",
|
|
3013
|
+
"today": "今日"
|
|
3014
|
+
}
|
|
3015
|
+
}, { appShell: {
|
|
2992
3016
|
"navigation": "ナビゲーション",
|
|
2993
3017
|
"expand": "サイドバーを展開",
|
|
2994
3018
|
"collapse": "サイドバーを折りたたむ",
|
|
@@ -3254,25 +3278,33 @@ var messages$1 = /* @__PURE__ */ mergeMessages({
|
|
|
3254
3278
|
"retry": "重试 {{name}}",
|
|
3255
3279
|
"remove": "移除 {{name}}"
|
|
3256
3280
|
}
|
|
3257
|
-
}, {
|
|
3258
|
-
|
|
3259
|
-
|
|
3260
|
-
|
|
3261
|
-
|
|
3262
|
-
|
|
3263
|
-
"
|
|
3264
|
-
|
|
3265
|
-
|
|
3266
|
-
|
|
3267
|
-
|
|
3268
|
-
|
|
3269
|
-
|
|
3270
|
-
|
|
3271
|
-
|
|
3272
|
-
|
|
3273
|
-
|
|
3274
|
-
|
|
3275
|
-
|
|
3281
|
+
}, {
|
|
3282
|
+
monthCalendar: {
|
|
3283
|
+
"label": "月历",
|
|
3284
|
+
"previousMonth": "上个月",
|
|
3285
|
+
"nextMonth": "下个月",
|
|
3286
|
+
"today": "今天",
|
|
3287
|
+
"weekdays": {
|
|
3288
|
+
"mon": "一",
|
|
3289
|
+
"tue": "二",
|
|
3290
|
+
"wed": "三",
|
|
3291
|
+
"thu": "四",
|
|
3292
|
+
"fri": "五",
|
|
3293
|
+
"sat": "六",
|
|
3294
|
+
"sun": "日"
|
|
3295
|
+
},
|
|
3296
|
+
"dayWithEvents_one": "{{date}},{{count}} 项日程",
|
|
3297
|
+
"dayWithEvents_other": "{{date}},{{count}} 项日程",
|
|
3298
|
+
"eventsLabel": "{{date}} 日程",
|
|
3299
|
+
"noEvents": "暂无日程"
|
|
3300
|
+
},
|
|
3301
|
+
datePicker: {
|
|
3302
|
+
"placeholder": "选择日期",
|
|
3303
|
+
"label": "日期",
|
|
3304
|
+
"clear": "清除日期",
|
|
3305
|
+
"today": "今天"
|
|
3306
|
+
}
|
|
3307
|
+
}, { appShell: {
|
|
3276
3308
|
"navigation": "导航",
|
|
3277
3309
|
"expand": "展开侧边栏",
|
|
3278
3310
|
"collapse": "收起侧边栏",
|
|
@@ -3761,6 +3793,23 @@ function addDays(date, days) {
|
|
|
3761
3793
|
function monthStart(date, offset = 0) {
|
|
3762
3794
|
return localDate(date.getFullYear(), date.getMonth() + offset, 1);
|
|
3763
3795
|
}
|
|
3796
|
+
var STRICT_DAY_KEY = /^(\d{4})-(\d{2})-(\d{2})$/;
|
|
3797
|
+
var LOOSE_DAY_KEY = /^\s*(\d{4})-(\d{1,2})-(\d{1,2})\s*$/;
|
|
3798
|
+
/**
|
|
3799
|
+
* Parses a `"YYYY-MM-DD"` string (or `"YYYY-M-D"` when `strict` is `false`)
|
|
3800
|
+
* into local midnight, rejecting out-of-range months and days (e.g. Feb 30).
|
|
3801
|
+
*/
|
|
3802
|
+
function parseDayKey(text, strict = true) {
|
|
3803
|
+
const match = (strict ? STRICT_DAY_KEY : LOOSE_DAY_KEY).exec(text);
|
|
3804
|
+
if (!match) return null;
|
|
3805
|
+
const year = Number(match[1]);
|
|
3806
|
+
const month = Number(match[2]);
|
|
3807
|
+
const day = Number(match[3]);
|
|
3808
|
+
if (month < 1 || month > 12 || day < 1 || day > 31) return null;
|
|
3809
|
+
const date = localDate(year, month - 1, day);
|
|
3810
|
+
if (date.getFullYear() !== year || date.getMonth() !== month - 1 || date.getDate() !== day) return null;
|
|
3811
|
+
return date;
|
|
3812
|
+
}
|
|
3764
3813
|
//#endregion
|
|
3765
3814
|
//#region ../core/src/number-input.ts
|
|
3766
3815
|
/** Decimal places of `step` (`0.05` -> 2); `0` for whole or missing steps. */
|
|
@@ -4009,6 +4058,9 @@ function labels(self) {
|
|
|
4009
4058
|
themeLight: t(self, "themeToggle.light"),
|
|
4010
4059
|
themeDark: t(self, "themeToggle.dark"),
|
|
4011
4060
|
themeSystem: t(self, "themeToggle.system"),
|
|
4061
|
+
dateLabel: t(self, "datePicker.label"),
|
|
4062
|
+
datePlaceholder: t(self, "datePicker.placeholder"),
|
|
4063
|
+
dateClear: t(self, "datePicker.clear"),
|
|
4012
4064
|
calendarLabel: t(self, "monthCalendar.label"),
|
|
4013
4065
|
calendarPrevious: t(self, "monthCalendar.previousMonth"),
|
|
4014
4066
|
calendarNext: t(self, "monthCalendar.nextMonth"),
|
|
@@ -6044,6 +6096,7 @@ var events = {
|
|
|
6044
6096
|
steps: [event("change", "{ value: string; current: number }", "Requested step and its index; readOnly defaults true.")],
|
|
6045
6097
|
table: tableEvents,
|
|
6046
6098
|
dataTable: [...tableEvents, event("retry", "{}", "Retry requested from the error state.")],
|
|
6099
|
+
datePicker: [event("change", "{ value: string }", "YYYY-MM-DD, or an empty string on clear; null/empty value remains controlled."), open],
|
|
6047
6100
|
timePicker: [event("change", "{ value: string | null }", "Serialized HH:mm[:ss], or null on clear; Date is not transmitted across the native property boundary."), open],
|
|
6048
6101
|
pageTabs: [
|
|
6049
6102
|
value,
|
|
@@ -8670,6 +8723,133 @@ var keyValueEditor = native(`<view class="mn-key-value"><view wx:for="{{rows}}"
|
|
|
8670
8723
|
}
|
|
8671
8724
|
}
|
|
8672
8725
|
});
|
|
8726
|
+
function datePickerCurrent(self) {
|
|
8727
|
+
return typeof self.data.value === "string" || self.data.value === null ? self.data.value ?? "" : self.data.localDateValue ?? self.data.defaultValue ?? "";
|
|
8728
|
+
}
|
|
8729
|
+
function datePickerAllowed(self, key) {
|
|
8730
|
+
return (!self.data.minDate || key >= self.data.minDate) && (!self.data.maxDate || key <= self.data.maxDate);
|
|
8731
|
+
}
|
|
8732
|
+
function datePickerOpen(self, open) {
|
|
8733
|
+
if (open && blocked(self) || self.data.opened === open) return;
|
|
8734
|
+
self.setData({ opened: open });
|
|
8735
|
+
self.triggerEvent("openchange", { open });
|
|
8736
|
+
}
|
|
8737
|
+
function datePickerCommit(self, key) {
|
|
8738
|
+
if (blocked(self)) return;
|
|
8739
|
+
if (typeof self.data.value !== "string" && self.data.value !== null) self.setData({ localDateValue: key });
|
|
8740
|
+
self.triggerEvent("change", { value: key });
|
|
8741
|
+
self.setData({ display: datePickerCurrent(self) });
|
|
8742
|
+
}
|
|
8743
|
+
var datePicker = native(`<view class="mn-date-picker mn-size-{{size}}"><text wx:if="{{label}}">{{label}}</text><input id="{{id}}" class="mn-input" value="{{display}}" name="{{name}}" placeholder="{{placeholder || localeLabels.datePlaceholder}}" aria-label="{{label || ariaLabel || localeLabels.dateLabel}}" aria-required="{{required}}" aria-invalid="{{invalid}}" disabled="{{disabled || readOnly}}" bindinput="onInput" bindblur="onBlur" bindconfirm="onBlur"/><picker class="mn-date-native" mode="date" value="{{current}}" start="{{minDate || '0001-01-01'}}" end="{{maxDate || '9999-12-31'}}" disabled="{{disabled || readOnly}}" bindtap="onOpen" catchchange="onChoose" bindcancel="onClose"><button class="mn-button mn-variant-ghost" disabled="{{disabled || readOnly}}" aria-label="{{label || ariaLabel || localeLabels.dateLabel}}">{{current || placeholder || localeLabels.datePlaceholder}}</button></picker><button wx:if="{{clearable && current && !disabled && !readOnly}}" class="mn-close mn-clear" aria-label="{{localeLabels.dateClear}}" bindtouchstart="onTouchControl" catchtap="onClear">×</button></view>`, {
|
|
8744
|
+
...common,
|
|
8745
|
+
value: {
|
|
8746
|
+
type: null,
|
|
8747
|
+
value: {}
|
|
8748
|
+
},
|
|
8749
|
+
defaultValue: string(),
|
|
8750
|
+
minDate: string(),
|
|
8751
|
+
maxDate: string(),
|
|
8752
|
+
label: string(),
|
|
8753
|
+
ariaLabel: string(),
|
|
8754
|
+
id: string(),
|
|
8755
|
+
placeholder: string(),
|
|
8756
|
+
name: string("date-picker"),
|
|
8757
|
+
clearable: {
|
|
8758
|
+
type: Boolean,
|
|
8759
|
+
value: true
|
|
8760
|
+
},
|
|
8761
|
+
required: flag(),
|
|
8762
|
+
invalid: flag(),
|
|
8763
|
+
size: string("medium")
|
|
8764
|
+
}, {
|
|
8765
|
+
onOpen() {
|
|
8766
|
+
datePickerOpen(this, true);
|
|
8767
|
+
},
|
|
8768
|
+
onClose() {
|
|
8769
|
+
datePickerOpen(this, false);
|
|
8770
|
+
},
|
|
8771
|
+
onChoose(event) {
|
|
8772
|
+
const parsed = parseDayKey(event.detail.value, true);
|
|
8773
|
+
if (parsed && datePickerAllowed(this, dayKey(parsed))) datePickerCommit(this, dayKey(parsed));
|
|
8774
|
+
this.setData({
|
|
8775
|
+
display: datePickerCurrent(this),
|
|
8776
|
+
current: datePickerCurrent(this),
|
|
8777
|
+
dateDraft: null
|
|
8778
|
+
});
|
|
8779
|
+
datePickerOpen(this, false);
|
|
8780
|
+
},
|
|
8781
|
+
onInput(event) {
|
|
8782
|
+
if (blocked(this)) return this.data.display;
|
|
8783
|
+
const text = event.detail.value, parsed = parseDayKey(text, true);
|
|
8784
|
+
this.setData({
|
|
8785
|
+
dateDraft: text,
|
|
8786
|
+
display: text
|
|
8787
|
+
});
|
|
8788
|
+
if (!text || parsed && datePickerAllowed(this, dayKey(parsed))) {
|
|
8789
|
+
datePickerCommit(this, parsed ? dayKey(parsed) : "");
|
|
8790
|
+
this.setData({
|
|
8791
|
+
display: text,
|
|
8792
|
+
current: datePickerCurrent(this)
|
|
8793
|
+
});
|
|
8794
|
+
}
|
|
8795
|
+
return text;
|
|
8796
|
+
},
|
|
8797
|
+
onBlur() {
|
|
8798
|
+
if (this.data.touchingDateControl) {
|
|
8799
|
+
this.setData({ touchingDateControl: false });
|
|
8800
|
+
return;
|
|
8801
|
+
}
|
|
8802
|
+
if (blocked(this) || this.data.dateDraft === null) return;
|
|
8803
|
+
const text = String(this.data.dateDraft).trim(), parsed = parseDayKey(text, false);
|
|
8804
|
+
const key = !text ? "" : parsed ? dayKey(parsed) : null;
|
|
8805
|
+
if (key !== null && (!key || datePickerAllowed(this, key)) && key !== datePickerCurrent(this)) datePickerCommit(this, key);
|
|
8806
|
+
this.setData({
|
|
8807
|
+
display: datePickerCurrent(this),
|
|
8808
|
+
current: datePickerCurrent(this),
|
|
8809
|
+
dateDraft: null
|
|
8810
|
+
});
|
|
8811
|
+
},
|
|
8812
|
+
onTouchControl() {
|
|
8813
|
+
this.setData({ touchingDateControl: true });
|
|
8814
|
+
},
|
|
8815
|
+
onClear() {
|
|
8816
|
+
if (blocked(this)) return;
|
|
8817
|
+
datePickerCommit(this, "");
|
|
8818
|
+
this.setData({
|
|
8819
|
+
display: datePickerCurrent(this),
|
|
8820
|
+
current: datePickerCurrent(this),
|
|
8821
|
+
dateDraft: null,
|
|
8822
|
+
touchingDateControl: false
|
|
8823
|
+
});
|
|
8824
|
+
}
|
|
8825
|
+
}, {
|
|
8826
|
+
data: {
|
|
8827
|
+
display: "",
|
|
8828
|
+
current: "",
|
|
8829
|
+
opened: false,
|
|
8830
|
+
dateDraft: null,
|
|
8831
|
+
touchingDateControl: false
|
|
8832
|
+
},
|
|
8833
|
+
lifetimes: { attached() {
|
|
8834
|
+
this.setData({ localDateValue: this.data.defaultValue });
|
|
8835
|
+
this.setData({
|
|
8836
|
+
display: datePickerCurrent(this),
|
|
8837
|
+
current: datePickerCurrent(this)
|
|
8838
|
+
});
|
|
8839
|
+
} },
|
|
8840
|
+
observers: {
|
|
8841
|
+
value: function() {
|
|
8842
|
+
this.setData({
|
|
8843
|
+
display: datePickerCurrent(this),
|
|
8844
|
+
current: datePickerCurrent(this),
|
|
8845
|
+
dateDraft: null
|
|
8846
|
+
});
|
|
8847
|
+
},
|
|
8848
|
+
"disabled,readOnly": function() {
|
|
8849
|
+
if (blocked(this)) datePickerOpen(this, false);
|
|
8850
|
+
}
|
|
8851
|
+
}
|
|
8852
|
+
});
|
|
8673
8853
|
var timePicker = native(`<picker mode="time" value="{{value}}" start="{{start}}" end="{{end}}" disabled="{{disabled || readOnly}}" bindchange="onChange"><view class="mn-input">{{value || placeholder}}</view></picker>`, {
|
|
8674
8854
|
...common,
|
|
8675
8855
|
value: string(),
|
|
@@ -10085,6 +10265,7 @@ enhanceFormContext([formControl, formField], [
|
|
|
10085
10265
|
rating,
|
|
10086
10266
|
ratingScale,
|
|
10087
10267
|
timePicker,
|
|
10268
|
+
datePicker,
|
|
10088
10269
|
upload
|
|
10089
10270
|
]);
|
|
10090
10271
|
enhanceFeedback({
|
|
@@ -10118,6 +10299,7 @@ annotateNativeApi({
|
|
|
10118
10299
|
jsonField,
|
|
10119
10300
|
keyValueEditor,
|
|
10120
10301
|
timePicker,
|
|
10302
|
+
datePicker,
|
|
10121
10303
|
monthCalendar,
|
|
10122
10304
|
pagination,
|
|
10123
10305
|
tabs,
|
|
@@ -10197,6 +10379,7 @@ exports.confirmDialog = confirmDialog;
|
|
|
10197
10379
|
exports.confirmProvider = confirmProvider;
|
|
10198
10380
|
exports.contextMenu = contextMenu;
|
|
10199
10381
|
exports.dataTable = dataTable;
|
|
10382
|
+
exports.datePicker = datePicker;
|
|
10200
10383
|
exports.descriptionList = descriptionList;
|
|
10201
10384
|
exports.divider = divider;
|
|
10202
10385
|
exports.drawer = drawer;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
Component(require('../controls.js').datePicker.definition);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"component":true}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<view class="mn-date-picker mn-size-{{size}}"><text wx:if="{{label}}">{{label}}</text><input id="{{id}}" class="mn-input" value="{{display}}" name="{{name}}" placeholder="{{placeholder || localeLabels.datePlaceholder}}" aria-label="{{label || ariaLabel || localeLabels.dateLabel}}" aria-required="{{required}}" aria-invalid="{{invalid}}" disabled="{{disabled || readOnly}}" bindinput="onInput" bindblur="onBlur" bindconfirm="onBlur"/><picker class="mn-date-native" mode="date" value="{{current}}" start="{{minDate || '0001-01-01'}}" end="{{maxDate || '9999-12-31'}}" disabled="{{disabled || readOnly}}" bindtap="onOpen" catchchange="onChoose" bindcancel="onClose"><button class="mn-button mn-variant-ghost" disabled="{{disabled || readOnly}}" aria-label="{{label || ariaLabel || localeLabels.dateLabel}}">{{current || placeholder || localeLabels.datePlaceholder}}</button></picker><button wx:if="{{clearable && current && !disabled && !readOnly}}" class="mn-close mn-clear" aria-label="{{localeLabels.dateClear}}" bindtouchstart="onTouchControl" catchtap="onClear">×</button></view>
|