0.0.2 • Published 2 years ago

w_units v0.0.2

Weekly downloads
-
License
ISC
Repository
-
Last release
2 years ago

简单工具集合

  • _date

    • _addZero(num : string | number)

      • 补零
    • _getDataTime(date : Date)

      • 获取 Y-M-D H:MI:S 格式的日期
    • _getDateStr(date : Date)

      • 获取 Y-M-D 格式的日期
    • _getWeekStr(date : Date)

      • 获取周几
    • _format(date : Date , str : string)

      • 格式化日期

        • l : 毫秒

        • Y : 年

        • M | m : 月

        • D | d : 日

        • H | h : 时

        • I | i : 分

        • S | s : 秒

          eg : Y-M-D H:I:S

  • _tips

    • _check

      • 内部方法 查重用
    • _close(id : string)

      • 关闭指定小提示
    • _onTime(_html : string , tipsTime : number , style : string)

      • 创建一个 tipsTime 后消失的小提示
    • _onConfirm(_html : string , callback : Function , btnFn : string[], style : string)

      • 创建一个带有选择功能的小提示

      • btnFn : 'cancel' , 'return'

      • callback 返回一个id 用来关闭这个窗口或者其他操作

    • _onLoad(_html : string , callback : Function , style : string)

      • 创建一个带有加载动画的小提示

      • callback 返回一个id 用来关闭这个窗口或者其他操作

0.0.2

2 years ago

0.0.1

2 years ago