@thi.ng/date 2.1.5 → 2.1.6

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  # Change Log
2
2
 
3
- - **Last updated**: 2022-03-11T12:13:49Z
3
+ - **Last updated**: 2022-04-07T14:17:30Z
4
4
  - **Generator**: [thi.ng/monopub](https://thi.ng/monopub)
5
5
 
6
6
  All notable changes to this project will be documented in this file.
@@ -9,6 +9,12 @@ See [Conventional Commits](https://conventionalcommits.org/) for commit guidelin
9
9
  **Note:** Unlisted _patch_ versions only involve non-code or otherwise excluded changes
10
10
  and/or version bumps of transitive dependencies.
11
11
 
12
+ ### [2.1.6](https://github.com/thi-ng/umbrella/tree/@thi.ng/date@2.1.6) (2022-04-07)
13
+
14
+ #### ♻️ Refactoring
15
+
16
+ - replace deprecated .substr() w/ .substring() ([0710509](https://github.com/thi-ng/umbrella/commit/0710509))
17
+
12
18
  ## [2.1.0](https://github.com/thi-ng/umbrella/tree/@thi.ng/date@2.1.0) (2021-11-17)
13
19
 
14
20
  #### 🚀 Features
package/format.js CHANGED
@@ -172,7 +172,7 @@ export const defFormat = (fmt) => (x, utc = false) => {
172
172
  let fn;
173
173
  return isString(x)
174
174
  ? x.startsWith("\\")
175
- ? x.substr(1)
175
+ ? x.substring(1)
176
176
  : (fn = FORMATTERS[x])
177
177
  ? fn(d, utc)
178
178
  : x
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thi.ng/date",
3
- "version": "2.1.5",
3
+ "version": "2.1.6",
4
4
  "description": "Datetime types, relative dates, math, iterators, composable formatters, locales",
5
5
  "type": "module",
6
6
  "module": "./index.js",
@@ -34,13 +34,13 @@
34
34
  "test": "testament test"
35
35
  },
36
36
  "dependencies": {
37
- "@thi.ng/api": "^8.3.4",
38
- "@thi.ng/checks": "^3.1.4",
39
- "@thi.ng/strings": "^3.3.2"
37
+ "@thi.ng/api": "^8.3.5",
38
+ "@thi.ng/checks": "^3.1.5",
39
+ "@thi.ng/strings": "^3.3.3"
40
40
  },
41
41
  "devDependencies": {
42
42
  "@microsoft/api-extractor": "^7.19.4",
43
- "@thi.ng/testament": "^0.2.4",
43
+ "@thi.ng/testament": "^0.2.5",
44
44
  "rimraf": "^3.0.2",
45
45
  "tools": "^0.0.1",
46
46
  "typedoc": "^0.22.13",
@@ -78,56 +78,56 @@
78
78
  ],
79
79
  "exports": {
80
80
  ".": {
81
- "import": "./index.js"
81
+ "default": "./index.js"
82
82
  },
83
83
  "./api": {
84
- "import": "./api.js"
84
+ "default": "./api.js"
85
85
  },
86
86
  "./checks": {
87
- "import": "./checks.js"
87
+ "default": "./checks.js"
88
88
  },
89
89
  "./datetime": {
90
- "import": "./datetime.js"
90
+ "default": "./datetime.js"
91
91
  },
92
92
  "./format": {
93
- "import": "./format.js"
93
+ "default": "./format.js"
94
94
  },
95
95
  "./i18n/de": {
96
- "import": "./i18n/de.js"
96
+ "default": "./i18n/de.js"
97
97
  },
98
98
  "./i18n/en": {
99
- "import": "./i18n/en.js"
99
+ "default": "./i18n/en.js"
100
100
  },
101
101
  "./i18n/es": {
102
- "import": "./i18n/es.js"
102
+ "default": "./i18n/es.js"
103
103
  },
104
104
  "./i18n/fr": {
105
- "import": "./i18n/fr.js"
105
+ "default": "./i18n/fr.js"
106
106
  },
107
107
  "./i18n/it": {
108
- "import": "./i18n/it.js"
108
+ "default": "./i18n/it.js"
109
109
  },
110
110
  "./i18n": {
111
- "import": "./i18n.js"
111
+ "default": "./i18n.js"
112
112
  },
113
113
  "./iterators": {
114
- "import": "./iterators.js"
114
+ "default": "./iterators.js"
115
115
  },
116
116
  "./relative": {
117
- "import": "./relative.js"
117
+ "default": "./relative.js"
118
118
  },
119
119
  "./round": {
120
- "import": "./round.js"
120
+ "default": "./round.js"
121
121
  },
122
122
  "./timecode": {
123
- "import": "./timecode.js"
123
+ "default": "./timecode.js"
124
124
  },
125
125
  "./units": {
126
- "import": "./units.js"
126
+ "default": "./units.js"
127
127
  }
128
128
  },
129
129
  "thi.ng": {
130
130
  "year": 2020
131
131
  },
132
- "gitHead": "0fc692a3225c068aacafdc4cb6140cf603c67ad8\n"
132
+ "gitHead": "5ee1feb590dd935593b1dd4e7f38a3ed3ba64765\n"
133
133
  }
package/relative.js CHANGED
@@ -77,7 +77,7 @@ const parseNum = (x, past) => (x === "next " || x === "a " || x === "an " ? 1 :
77
77
  const parsePeriod = (x) => {
78
78
  x =
79
79
  x !== "s" && x !== "ms" && x.endsWith("s")
80
- ? x.substr(0, x.length - 1)
80
+ ? x.substring(0, x.length - 1)
81
81
  : x;
82
82
  return {
83
83
  ms: "t",