plain-design 1.0.0-beta.53 → 1.0.0-beta.55

Sign up to get free protection for your applications and to get access to all the features.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "plain-design",
3
- "version": "1.0.0-beta.53",
3
+ "version": "1.0.0-beta.55",
4
4
  "description": "",
5
5
  "main": "dist/plain-design.min.js",
6
6
  "module": "dist/plain-design.commonjs.min.js",
@@ -211,6 +211,7 @@ export type {tEditComputed, tEditControl, EditProvideData} from './uses/useEdit'
211
211
  export {useStyle, StyleProps, ThemeShape, ThemeSize, ThemeStatus} from './uses/useStyle';
212
212
  export type {tStyleComputed, UseStyleProvideData} from './uses/useStyle';
213
213
  export {AutoLoadingObserver} from './components/AutoLoadingObserver';
214
+ export {lighter, darken} from './utils/color.utils';
214
215
 
215
216
  // @ts-ignore
216
217
  setComponentPrefix(globalComponentPrefix);
@@ -192,8 +192,12 @@ const parse = (str: string | undefined | null, format: string) => {
192
192
  * @author 韦胜健
193
193
  * @date 2021/1/18 10:30
194
194
  */
195
- const today = (displayFormat: string, valueFormat: string) => {
195
+ const today = (displayFormat: string = 'YYYY-MM-DD', valueFormat: string = 'YYYY-MM-DD') => {
196
196
  return wrapDate(new Date(), { displayFormat, valueFormat });
197
197
  };
198
198
 
199
- export const plainDate = Object.assign(wrapDate, { defaultDate, format, parse, today, DayJs });
199
+ const now = (displayFormat: string = 'YYYY-MM-DD HH:mm:ss', valueFormat: string = 'YYYY-MM-DD HH:mm:ss') => {
200
+ return wrapDate(new Date(), { displayFormat, valueFormat });
201
+ };
202
+
203
+ export const plainDate = Object.assign(wrapDate, { defaultDate, format, parse, today, now, DayJs });