tinacms 0.0.0-a1ff961-20250623024558 → 0.0.0-a23fec8-20251217045135

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 (87) hide show
  1. package/dist/admin/api.d.ts +4 -1
  2. package/dist/auth/AuthModal.d.ts +1 -4
  3. package/dist/auth/TinaCloudProvider.d.ts +0 -1
  4. package/dist/cache/node-cache.d.ts +6 -2
  5. package/dist/client.js +240 -181
  6. package/dist/index.js +120164 -118241
  7. package/dist/internalClient/index.d.ts +55 -2
  8. package/dist/react.js +209 -210
  9. package/dist/rich-text/index.d.ts +6 -0
  10. package/dist/rich-text/index.js +234 -230
  11. package/dist/rich-text/prism.js +16 -18
  12. package/dist/rich-text/static.d.ts +154 -0
  13. package/dist/rich-text/{index.mjs → static.js} +90 -96
  14. package/dist/tina-cms.d.ts +1 -1
  15. package/dist/toolkit/components/ProgressBar.d.ts +11 -0
  16. package/dist/toolkit/components/media/media-item.d.ts +10 -0
  17. package/dist/toolkit/components/ui/button.d.ts +11 -0
  18. package/dist/toolkit/components/ui/calendar.d.ts +8 -0
  19. package/dist/toolkit/components/ui/date-time-picker.d.ts +111 -0
  20. package/dist/toolkit/components/ui/input.d.ts +3 -0
  21. package/dist/toolkit/components/ui/popover.d.ts +7 -0
  22. package/dist/toolkit/components/ui/select.d.ts +13 -0
  23. package/dist/toolkit/fields/components/color-picker/block-widget.d.ts +3 -0
  24. package/dist/toolkit/fields/components/color-picker/color-input.d.ts +35 -0
  25. package/dist/toolkit/fields/components/color-picker/color-picker.d.ts +6 -2
  26. package/dist/toolkit/fields/components/color-picker/color-utils.d.ts +37 -0
  27. package/dist/toolkit/fields/components/color-picker/sketch-widget.d.ts +3 -0
  28. package/dist/toolkit/fields/components/select.d.ts +1 -1
  29. package/dist/toolkit/fields/plugins/button-toggle-field-plugin.d.ts +2 -2
  30. package/dist/toolkit/fields/plugins/checkbox-group-field-plugin.d.ts +2 -2
  31. package/dist/toolkit/fields/plugins/color-field-plugin.d.ts +1 -0
  32. package/dist/toolkit/fields/plugins/date-field-plugin.d.ts +0 -2
  33. package/dist/toolkit/fields/plugins/dnd-kit-wrapper.d.ts +49 -0
  34. package/dist/toolkit/fields/plugins/group-list-field-plugin.d.ts +3 -1
  35. package/dist/toolkit/fields/plugins/list-field-plugin.d.ts +3 -0
  36. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/editor.d.ts +2 -2
  37. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/blockquote-element.d.ts +1 -1
  38. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/button.d.ts +2 -2
  39. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/code-block/code-block-element.d.ts +1 -1
  40. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/code-line-element.d.ts +1 -1
  41. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/command.d.ts +7 -7
  42. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/list-element.d.ts +2 -2
  43. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/paragraph-element.d.ts +1 -1
  44. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/slash-input-element.d.ts +1 -1
  45. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/table/table-cell-element.d.ts +2 -2
  46. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/table/table-element.d.ts +1 -1
  47. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/table/table-row-element.d.ts +1 -1
  48. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/components/plate-ui/use-floating-toolbar-hook.d.ts +1 -1
  49. package/dist/toolkit/fields/plugins/mdx-field-plugin/plate/plugins/ui/components.d.ts +20 -19
  50. package/dist/toolkit/fields/plugins/radio-group-field-plugin.d.ts +2 -2
  51. package/dist/toolkit/fields/plugins/select-field-plugin.d.ts +2 -2
  52. package/dist/toolkit/fields/plugins/toggle-field-plugin.d.ts +2 -2
  53. package/dist/toolkit/form-builder/create-branch-modal.d.ts +13 -0
  54. package/dist/toolkit/form-builder/editorial-workflow-constants.d.ts +17 -0
  55. package/dist/toolkit/form-builder/form-builder.d.ts +0 -11
  56. package/dist/toolkit/form-builder/index.d.ts +1 -0
  57. package/dist/toolkit/icons/TinaExtended.d.ts +4 -0
  58. package/dist/toolkit/icons/index.d.ts +1 -0
  59. package/dist/toolkit/index.d.ts +1 -1
  60. package/dist/toolkit/plugin-branch-switcher/branch-button.d.ts +3 -1
  61. package/dist/toolkit/react-modals/modal/modal-actions.d.ts +2 -1
  62. package/dist/toolkit/react-modals/modal/modal-header.d.ts +1 -1
  63. package/dist/toolkit/react-sidebar/components/NavMenuTrigger.d.ts +11 -0
  64. package/dist/toolkit/react-sidebar/components/VersionInfo.d.ts +2 -0
  65. package/dist/toolkit/react-sidebar/components/badge.d.ts +6 -0
  66. package/dist/toolkit/react-sidebar/components/callout.d.ts +5 -0
  67. package/dist/toolkit/react-sidebar/components/local-warning.d.ts +3 -1
  68. package/dist/toolkit/react-sidebar/components/nav-components.d.ts +11 -0
  69. package/dist/toolkit/react-sidebar/components/nav-context.d.ts +15 -0
  70. package/dist/toolkit/react-sidebar/components/nav.d.ts +3 -2
  71. package/dist/toolkit/react-sidebar/components/sidebar-body.d.ts +26 -1
  72. package/dist/toolkit/react-sidebar/index.d.ts +3 -0
  73. package/dist/toolkit/styles/button.d.ts +1 -1
  74. package/dist/toolkit/styles/dropdown-button.d.ts +75 -0
  75. package/dist/toolkit/styles/index.d.ts +1 -0
  76. package/dist/unifiedClient/index.d.ts +1 -1
  77. package/dist/utils/index.d.ts +1 -0
  78. package/package.json +34 -65
  79. package/dist/admin/pages/IndexingPage.d.ts +0 -2
  80. package/dist/client.mjs +0 -132
  81. package/dist/index.mjs +0 -121720
  82. package/dist/node-cache-5e8db9f0.mjs +0 -63
  83. package/dist/react.mjs +0 -252
  84. package/dist/rich-text/prism.mjs +0 -16
  85. package/dist/toolkit/react-datetime/DateTime.d.ts +0 -135
  86. package/dist/toolkit/react-sidebar/components/alert.d.ts +0 -5
  87. /package/dist/admin/components/{Sidebar.d.ts → AdminNav.d.ts} +0 -0
@@ -1,63 +0,0 @@
1
- const makeCacheDir = async (dir, fs, path, os) => {
2
- const pathParts = dir.split(path.sep).filter(Boolean);
3
- const cacheHash = pathParts[pathParts.length - 1];
4
- const rootUser = pathParts[0];
5
- let cacheDir = dir;
6
- if (!fs.existsSync(path.join(path.sep, rootUser))) {
7
- cacheDir = path.join(os.tmpdir(), cacheHash);
8
- }
9
- try {
10
- fs.mkdirSync(cacheDir, { recursive: true });
11
- } catch (error) {
12
- throw new Error(`Failed to create cache directory: ${error.message}`);
13
- }
14
- return cacheDir;
15
- };
16
- const NodeCache = async (dir) => {
17
- const fs = require("node:fs");
18
- const path = require("node:path");
19
- const os = require("node:os");
20
- const { createHash } = require("node:crypto");
21
- const cacheDir = await makeCacheDir(dir, fs, path, os);
22
- return {
23
- makeKey: (key) => {
24
- const input = key && key instanceof Object ? JSON.stringify(key) : key || "";
25
- return createHash("sha256").update(input).digest("hex");
26
- },
27
- get: async (key) => {
28
- let readValue;
29
- const cacheFilename = `${cacheDir}/${key}`;
30
- try {
31
- const data = await fs.promises.readFile(cacheFilename, "utf-8");
32
- readValue = JSON.parse(data);
33
- } catch (e) {
34
- if (e.code !== "ENOENT") {
35
- console.error(
36
- `Failed to read cache file to ${cacheFilename}: ${e.message}`
37
- );
38
- }
39
- }
40
- return readValue;
41
- },
42
- set: async (key, value) => {
43
- const cacheFilename = `${cacheDir}/${key}`;
44
- try {
45
- await fs.promises.writeFile(cacheFilename, JSON.stringify(value), {
46
- encoding: "utf-8",
47
- flag: "wx"
48
- // Don't overwrite existing caches
49
- });
50
- } catch (e) {
51
- if (e.code !== "EEXIST") {
52
- console.error(
53
- `Failed to write cache file to ${cacheFilename}: ${e.message}`
54
- );
55
- }
56
- }
57
- }
58
- };
59
- };
60
- export {
61
- NodeCache,
62
- makeCacheDir
63
- };
package/dist/react.mjs DELETED
@@ -1,252 +0,0 @@
1
- import React from "react";
2
- function useTina(props) {
3
- const stringifiedQuery = JSON.stringify({
4
- query: props.query,
5
- variables: props.variables
6
- });
7
- const id = React.useMemo(
8
- () => hashFromQuery(stringifiedQuery),
9
- [stringifiedQuery]
10
- );
11
- const processedData = React.useMemo(() => {
12
- const dataCopy = JSON.parse(JSON.stringify(props.data));
13
- return addMetadata(id, dataCopy, []);
14
- }, [props.data, id]);
15
- const [data, setData] = React.useState(processedData);
16
- const [isClient, setIsClient] = React.useState(false);
17
- const [quickEditEnabled, setQuickEditEnabled] = React.useState(false);
18
- const [isInTinaIframe, setIsInTinaIframe] = React.useState(false);
19
- React.useEffect(() => {
20
- setIsClient(true);
21
- setData(processedData);
22
- parent.postMessage({
23
- type: "url-changed"
24
- });
25
- }, [id, processedData]);
26
- React.useEffect(() => {
27
- if (quickEditEnabled) {
28
- let mouseDownHandler = function(e) {
29
- const attributeNames = e.target.getAttributeNames();
30
- const tinaAttribute = attributeNames.find(
31
- (name) => name.startsWith("data-tina-field")
32
- );
33
- let fieldName;
34
- if (tinaAttribute) {
35
- e.preventDefault();
36
- e.stopPropagation();
37
- fieldName = e.target.getAttribute(tinaAttribute);
38
- } else {
39
- const ancestor = e.target.closest(
40
- "[data-tina-field], [data-tina-field-overlay]"
41
- );
42
- if (ancestor) {
43
- const attributeNames2 = ancestor.getAttributeNames();
44
- const tinaAttribute2 = attributeNames2.find(
45
- (name) => name.startsWith("data-tina-field")
46
- );
47
- if (tinaAttribute2) {
48
- e.preventDefault();
49
- e.stopPropagation();
50
- fieldName = ancestor.getAttribute(tinaAttribute2);
51
- }
52
- }
53
- }
54
- if (fieldName) {
55
- if (isInTinaIframe) {
56
- parent.postMessage(
57
- { type: "field:selected", fieldName },
58
- window.location.origin
59
- );
60
- }
61
- }
62
- };
63
- const style = document.createElement("style");
64
- style.type = "text/css";
65
- style.textContent = `
66
- [data-tina-field] {
67
- outline: 2px dashed rgba(34,150,254,0.5);
68
- transition: box-shadow ease-out 150ms;
69
- }
70
- [data-tina-field]:hover {
71
- box-shadow: inset 100vi 100vh rgba(34,150,254,0.3);
72
- outline: 2px solid rgba(34,150,254,1);
73
- cursor: pointer;
74
- }
75
- [data-tina-field-overlay] {
76
- outline: 2px dashed rgba(34,150,254,0.5);
77
- position: relative;
78
- }
79
- [data-tina-field-overlay]:hover {
80
- cursor: pointer;
81
- outline: 2px solid rgba(34,150,254,1);
82
- }
83
- [data-tina-field-overlay]::after {
84
- content: '';
85
- position: absolute;
86
- inset: 0;
87
- z-index: 20;
88
- transition: opacity ease-out 150ms;
89
- background-color: rgba(34,150,254,0.3);
90
- opacity: 0;
91
- }
92
- [data-tina-field-overlay]:hover::after {
93
- opacity: 1;
94
- }
95
- `;
96
- document.head.appendChild(style);
97
- document.body.classList.add("__tina-quick-editing-enabled");
98
- document.addEventListener("click", mouseDownHandler, true);
99
- return () => {
100
- document.removeEventListener("click", mouseDownHandler, true);
101
- document.body.classList.remove("__tina-quick-editing-enabled");
102
- style.remove();
103
- };
104
- }
105
- }, [quickEditEnabled, isInTinaIframe]);
106
- React.useEffect(() => {
107
- if (props == null ? void 0 : props.experimental___selectFormByFormId) {
108
- parent.postMessage({
109
- type: "user-select-form",
110
- formId: props.experimental___selectFormByFormId()
111
- });
112
- }
113
- }, [id]);
114
- React.useEffect(() => {
115
- const { experimental___selectFormByFormId, ...rest } = props;
116
- parent.postMessage({ type: "open", ...rest, id }, window.location.origin);
117
- const handleMessage = (event) => {
118
- if (event.data.type === "quickEditEnabled") {
119
- setQuickEditEnabled(event.data.value);
120
- }
121
- if (event.data.id === id && event.data.type === "updateData") {
122
- const rawData = event.data.data;
123
- const newlyProcessedData = addMetadata(
124
- id,
125
- JSON.parse(JSON.stringify(rawData)),
126
- []
127
- );
128
- setData(newlyProcessedData);
129
- setIsInTinaIframe(true);
130
- const anyTinaField = document.querySelector("[data-tina-field]");
131
- if (anyTinaField) {
132
- parent.postMessage(
133
- { type: "quick-edit", value: true },
134
- window.location.origin
135
- );
136
- } else {
137
- parent.postMessage(
138
- { type: "quick-edit", value: false },
139
- window.location.origin
140
- );
141
- }
142
- }
143
- };
144
- window.addEventListener("message", handleMessage);
145
- return () => {
146
- window.removeEventListener("message", handleMessage);
147
- parent.postMessage({ type: "close", id }, window.location.origin);
148
- };
149
- }, [id, setQuickEditEnabled]);
150
- return { data, isClient };
151
- }
152
- function useEditState() {
153
- const [edit, setEdit] = React.useState(false);
154
- React.useEffect(() => {
155
- if (typeof window !== "undefined") {
156
- parent.postMessage({ type: "isEditMode" }, window.location.origin);
157
- window.addEventListener("message", (event) => {
158
- var _a;
159
- if (((_a = event.data) == null ? void 0 : _a.type) === "tina:editMode") {
160
- setEdit(true);
161
- }
162
- });
163
- }
164
- }, []);
165
- return { edit };
166
- }
167
- const tinaField = (object, property, index) => {
168
- const contentSource = object == null ? void 0 : object._content_source;
169
- if (!contentSource) {
170
- return "";
171
- }
172
- const { queryId, path } = contentSource;
173
- if (!property) {
174
- return `${queryId}---${path.join(".")}`;
175
- }
176
- const fullPath = typeof index === "number" ? [...path, property, index] : [...path, property];
177
- return `${queryId}---${fullPath.join(".")}`;
178
- };
179
- const addMetadata = (id, obj, path = []) => {
180
- if (obj === null) {
181
- return obj;
182
- }
183
- if (isScalarOrUndefined(obj)) {
184
- return obj;
185
- }
186
- if (obj instanceof String) {
187
- return obj.valueOf();
188
- }
189
- if (Array.isArray(obj)) {
190
- return obj.map(
191
- (item, index) => addMetadata(id, item, [...path, index])
192
- );
193
- }
194
- const transformedObj = {};
195
- for (const [key, value] of Object.entries(obj)) {
196
- const currentPath = [...path, key];
197
- if ([
198
- "__typename",
199
- "_sys",
200
- "_internalSys",
201
- "_values",
202
- "_internalValues",
203
- "_content_source",
204
- "_tina_metadata"
205
- ].includes(key)) {
206
- transformedObj[key] = value;
207
- } else {
208
- transformedObj[key] = addMetadata(id, value, currentPath);
209
- }
210
- }
211
- if (transformedObj && typeof transformedObj === "object" && "type" in transformedObj && transformedObj.type === "root") {
212
- return transformedObj;
213
- }
214
- return { ...transformedObj, _content_source: { queryId: id, path } };
215
- };
216
- function isScalarOrUndefined(value) {
217
- const type = typeof value;
218
- if (type === "string")
219
- return true;
220
- if (type === "number")
221
- return true;
222
- if (type === "boolean")
223
- return true;
224
- if (type === "undefined")
225
- return true;
226
- if (value == null)
227
- return true;
228
- if (value instanceof String)
229
- return true;
230
- if (value instanceof Number)
231
- return true;
232
- if (value instanceof Boolean)
233
- return true;
234
- return false;
235
- }
236
- const hashFromQuery = (input) => {
237
- let hash = 0;
238
- for (let i = 0; i < input.length; i++) {
239
- const char = input.charCodeAt(i);
240
- hash = (hash << 5) - hash + char & 4294967295;
241
- }
242
- const nonNegativeHash = Math.abs(hash);
243
- const alphanumericHash = nonNegativeHash.toString(36);
244
- return alphanumericHash;
245
- };
246
- export {
247
- addMetadata,
248
- hashFromQuery,
249
- tinaField,
250
- useEditState,
251
- useTina
252
- };
@@ -1,16 +0,0 @@
1
- import React from "react";
2
- import { Highlight, themes } from "prism-react-renderer";
3
- const Prism = (props) => {
4
- return /* @__PURE__ */ React.createElement(
5
- Highlight,
6
- {
7
- theme: themes[props.theme || "github"],
8
- code: props.value || "",
9
- language: props.lang || ""
10
- },
11
- ({ className, style, tokens, getLineProps, getTokenProps }) => /* @__PURE__ */ React.createElement("pre", { className, style }, tokens.map((line, i) => /* @__PURE__ */ React.createElement("div", { ...getLineProps({ line, key: i }) }, line.map((token, key) => /* @__PURE__ */ React.createElement("span", { ...getTokenProps({ token, key }) })))))
12
- );
13
- };
14
- export {
15
- Prism
16
- };
@@ -1,135 +0,0 @@
1
- export default class Datetime extends React.Component<any, any, any> {
2
- static propTypes: {
3
- value: PropTypes.Requireable<NonNullable<string | Date>>;
4
- initialValue: PropTypes.Requireable<NonNullable<string | Date>>;
5
- initialViewDate: PropTypes.Requireable<NonNullable<string | Date>>;
6
- initialViewMode: PropTypes.Requireable<string>;
7
- onOpen: PropTypes.Requireable<(...args: any[]) => any>;
8
- onClose: PropTypes.Requireable<(...args: any[]) => any>;
9
- onChange: PropTypes.Requireable<(...args: any[]) => any>;
10
- onNavigate: PropTypes.Requireable<(...args: any[]) => any>;
11
- onBeforeNavigate: PropTypes.Requireable<(...args: any[]) => any>;
12
- onNavigateBack: PropTypes.Requireable<(...args: any[]) => any>;
13
- onNavigateForward: PropTypes.Requireable<(...args: any[]) => any>;
14
- updateOnView: PropTypes.Requireable<string>;
15
- locale: PropTypes.Requireable<string>;
16
- utc: PropTypes.Requireable<boolean>;
17
- displayTimeZone: PropTypes.Requireable<string>;
18
- input: PropTypes.Requireable<boolean>;
19
- dateFormat: PropTypes.Requireable<NonNullable<string | boolean>>;
20
- timeFormat: PropTypes.Requireable<NonNullable<string | boolean>>;
21
- inputProps: PropTypes.Requireable<object>;
22
- timeConstraints: PropTypes.Requireable<object>;
23
- isValidDate: PropTypes.Requireable<(...args: any[]) => any>;
24
- open: PropTypes.Requireable<boolean>;
25
- strictParsing: PropTypes.Requireable<boolean>;
26
- closeOnSelect: PropTypes.Requireable<boolean>;
27
- closeOnTab: PropTypes.Requireable<boolean>;
28
- renderView: PropTypes.Requireable<(...args: any[]) => any>;
29
- renderInput: PropTypes.Requireable<(...args: any[]) => any>;
30
- renderDay: PropTypes.Requireable<(...args: any[]) => any>;
31
- renderMonth: PropTypes.Requireable<(...args: any[]) => any>;
32
- renderYear: PropTypes.Requireable<(...args: any[]) => any>;
33
- };
34
- static defaultProps: {
35
- onOpen: () => void;
36
- onClose: () => void;
37
- onCalendarOpen: () => void;
38
- onCalendarClose: () => void;
39
- onChange: () => void;
40
- onNavigate: () => void;
41
- onBeforeNavigate: (next: any) => any;
42
- onNavigateBack: () => void;
43
- onNavigateForward: () => void;
44
- dateFormat: boolean;
45
- timeFormat: boolean;
46
- utc: boolean;
47
- className: string;
48
- input: boolean;
49
- inputProps: {};
50
- timeConstraints: {};
51
- isValidDate: () => boolean;
52
- strictParsing: boolean;
53
- closeOnSelect: boolean;
54
- closeOnTab: boolean;
55
- closeOnClickOutside: boolean;
56
- renderView: (_: any, renderFunc: any) => any;
57
- };
58
- static moment: typeof moment;
59
- constructor(props: any);
60
- state: {
61
- open: boolean;
62
- currentView: any;
63
- viewDate: any;
64
- selectedDate: any;
65
- inputValue: any;
66
- };
67
- render(): React.JSX.Element;
68
- renderInput(): React.JSX.Element;
69
- renderView(): any;
70
- _renderCalendar: () => React.JSX.Element;
71
- getInitialState(): {
72
- open: boolean;
73
- currentView: any;
74
- viewDate: any;
75
- selectedDate: any;
76
- inputValue: any;
77
- };
78
- getInitialViewDate(selectedDate: any): any;
79
- getInitialDate(): any;
80
- getInitialView(): any;
81
- parseDate(date: any, dateFormat: any): any;
82
- getClassName(): string;
83
- isOpen(): any;
84
- getUpdateOn(dateFormat: any): any;
85
- getLocaleData(): any;
86
- getDateFormat(): any;
87
- getTimeFormat(): any;
88
- getFormat(type: any): any;
89
- _showView: (view: any, date: any) => void;
90
- updateTime(op: any, amount: any, type: any, toSelected: any): void;
91
- viewToMethod: {
92
- days: string;
93
- months: string;
94
- years: string;
95
- };
96
- nextView: {
97
- days: string;
98
- months: string;
99
- years: string;
100
- };
101
- _updateDate: (e: any) => void;
102
- _viewNavigate: (modifier: any, unit: any) => void;
103
- _setTime: (type: any, value: any) => void;
104
- _openCalendar: () => void;
105
- _closeCalendar: () => void;
106
- _handleClickOutside: () => void;
107
- localMoment(date: any, format: any, props: any): any;
108
- checkTZ(): void;
109
- tzWarning: boolean;
110
- componentDidUpdate(prevProps: any): void;
111
- regenerateDates(): void;
112
- getSelectedDate(): any;
113
- getInitialInputValue(selectedDate: any): any;
114
- getInputValue(): any;
115
- /**
116
- * Set the date that is currently shown in the calendar.
117
- * This is independent from the selected date and it's the one used to navigate through months or days in the calendar.
118
- * @param dateType date
119
- * @public
120
- */
121
- public setViewDate(date: any): void;
122
- /**
123
- * Set the view currently shown by the calendar. View modes shipped with react-datetime are 'years', 'months', 'days' and 'time'.
124
- * @param TYPES.string mode
125
- */
126
- navigate(mode: any): void;
127
- _onInputFocus: (e: any) => void;
128
- _onInputChange: (e: any) => void;
129
- _onInputKeyDown: (e: any) => void;
130
- _onInputClick: (e: any) => void;
131
- callHandler(method: any, e: any): boolean;
132
- }
133
- import React from 'react';
134
- import PropTypes from 'prop-types';
135
- import moment from 'moment';
@@ -1,5 +0,0 @@
1
- import * as React from 'react';
2
- export declare const Alert: ({ children, alertStyle, className, ...props }: {
3
- children?: React.ReactNode;
4
- alertStyle?: "warning";
5
- } & React.HTMLProps<HTMLDivElement>) => React.JSX.Element;