@scaleway/regex 2.0.0 → 2.1.0
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 +9 -0
- package/dist/index.browser.js +3 -2
- package/dist/index.d.ts +2 -1
- package/dist/index.js +3 -2
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,15 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## 2.1.0 (2021-11-23)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Features
|
|
10
|
+
|
|
11
|
+
* add absolute path regex ([#514](https://github.com/scaleway/scaleway-lib/issues/514)) ([f271d72](https://github.com/scaleway/scaleway-lib/commit/f271d7251198f2119480a02dce844a283452e061))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
6
15
|
## 2.0.0 (2021-07-20)
|
|
7
16
|
|
|
8
17
|
|
package/dist/index.browser.js
CHANGED
|
@@ -10,7 +10,8 @@ const alphanumdots = /^[a-zA-Z0-9.]*$/;
|
|
|
10
10
|
const alphanumLowercase = /^[a-z0-9]+$/;
|
|
11
11
|
const alphanumSpacesDotsUnderscoreDash = /^[a-zA-Z0-9-.\s_]*$/;
|
|
12
12
|
const alphanumUnderscoreDash = /^[a-zA-Z0-9_-]*$/;
|
|
13
|
-
const alphanumUnderscoreDollarDash = /^[a-zA-Z0-9_$-]*$/;
|
|
13
|
+
const alphanumUnderscoreDollarDash = /^[a-zA-Z0-9_$-]*$/;
|
|
14
|
+
const absoluteLinuxPath = /(^\/$|^(\/[a-zA-Z0-9_]+)*$)/; // eslint-disable-next-line no-control-regex
|
|
14
15
|
|
|
15
16
|
const ascii = /^[\x00-\x7F]+$/;
|
|
16
17
|
const backupKey = /^[A-Z0-9]{32}$/;
|
|
@@ -26,4 +27,4 @@ const sixDigitsCode = /^[0-9]{6}$/;
|
|
|
26
27
|
const url = /^(http:\/\/www\.|https:\/\/www\.|http:\/\/|https:\/\/)?[a-z0-9]+([-.]{1}[a-z0-9]+)*\.[a-z]{2,5}(:[0-9]{1,5})?(\/.*)?$/;
|
|
27
28
|
const hexadecimal = /^[0-9a-fA-F]+$/;
|
|
28
29
|
|
|
29
|
-
export { alpha, alphanum, alphanumLowercase, alphanumSpacesDotsUnderscoreDash, alphanumUnderscoreDash, alphanumUnderscoreDollarDash, alphanumdash, alphanumdashdots, alphanumdashdotsorempty, alphanumdashdotsspaces, alphanumdashorempty, alphanumdashspaces, alphanumdots, ascii, backupKey, cron, digits, email, fourDigitsCode, hexadecimal, macAddress, phone, sixDigitsCode, spaces, url };
|
|
30
|
+
export { absoluteLinuxPath, alpha, alphanum, alphanumLowercase, alphanumSpacesDotsUnderscoreDash, alphanumUnderscoreDash, alphanumUnderscoreDollarDash, alphanumdash, alphanumdashdots, alphanumdashdotsorempty, alphanumdashdotsspaces, alphanumdashorempty, alphanumdashspaces, alphanumdots, ascii, backupKey, cron, digits, email, fourDigitsCode, hexadecimal, macAddress, phone, sixDigitsCode, spaces, url };
|
package/dist/index.d.ts
CHANGED
|
@@ -11,6 +11,7 @@ declare const alphanumLowercase: RegExp;
|
|
|
11
11
|
declare const alphanumSpacesDotsUnderscoreDash: RegExp;
|
|
12
12
|
declare const alphanumUnderscoreDash: RegExp;
|
|
13
13
|
declare const alphanumUnderscoreDollarDash: RegExp;
|
|
14
|
+
declare const absoluteLinuxPath: RegExp;
|
|
14
15
|
declare const ascii: RegExp;
|
|
15
16
|
declare const backupKey: RegExp;
|
|
16
17
|
declare const cron: RegExp;
|
|
@@ -24,4 +25,4 @@ declare const sixDigitsCode: RegExp;
|
|
|
24
25
|
declare const url: RegExp;
|
|
25
26
|
declare const hexadecimal: RegExp;
|
|
26
27
|
|
|
27
|
-
export { alpha, alphanum, alphanumLowercase, alphanumSpacesDotsUnderscoreDash, alphanumUnderscoreDash, alphanumUnderscoreDollarDash, alphanumdash, alphanumdashdots, alphanumdashdotsorempty, alphanumdashdotsspaces, alphanumdashorempty, alphanumdashspaces, alphanumdots, ascii, backupKey, cron, digits, email, fourDigitsCode, hexadecimal, macAddress, phone, sixDigitsCode, spaces, url };
|
|
28
|
+
export { absoluteLinuxPath, alpha, alphanum, alphanumLowercase, alphanumSpacesDotsUnderscoreDash, alphanumUnderscoreDash, alphanumUnderscoreDollarDash, alphanumdash, alphanumdashdots, alphanumdashdotsorempty, alphanumdashdotsspaces, alphanumdashorempty, alphanumdashspaces, alphanumdots, ascii, backupKey, cron, digits, email, fourDigitsCode, hexadecimal, macAddress, phone, sixDigitsCode, spaces, url };
|
package/dist/index.js
CHANGED
|
@@ -10,7 +10,8 @@ const alphanumdots = /^[a-zA-Z0-9.]*$/;
|
|
|
10
10
|
const alphanumLowercase = /^[a-z0-9]+$/;
|
|
11
11
|
const alphanumSpacesDotsUnderscoreDash = /^[a-zA-Z0-9-.\s_]*$/;
|
|
12
12
|
const alphanumUnderscoreDash = /^[a-zA-Z0-9_-]*$/;
|
|
13
|
-
const alphanumUnderscoreDollarDash = /^[a-zA-Z0-9_$-]*$/;
|
|
13
|
+
const alphanumUnderscoreDollarDash = /^[a-zA-Z0-9_$-]*$/;
|
|
14
|
+
const absoluteLinuxPath = /(^\/$|^(\/[a-zA-Z0-9_]+)*$)/; // eslint-disable-next-line no-control-regex
|
|
14
15
|
|
|
15
16
|
const ascii = /^[\x00-\x7F]+$/;
|
|
16
17
|
const backupKey = /^[A-Z0-9]{32}$/;
|
|
@@ -26,4 +27,4 @@ const sixDigitsCode = /^[0-9]{6}$/;
|
|
|
26
27
|
const url = /^(http:\/\/www\.|https:\/\/www\.|http:\/\/|https:\/\/)?[a-z0-9]+([-.]{1}[a-z0-9]+)*\.[a-z]{2,5}(:[0-9]{1,5})?(\/.*)?$/;
|
|
27
28
|
const hexadecimal = /^[0-9a-fA-F]+$/;
|
|
28
29
|
|
|
29
|
-
export { alpha, alphanum, alphanumLowercase, alphanumSpacesDotsUnderscoreDash, alphanumUnderscoreDash, alphanumUnderscoreDollarDash, alphanumdash, alphanumdashdots, alphanumdashdotsorempty, alphanumdashdotsspaces, alphanumdashorempty, alphanumdashspaces, alphanumdots, ascii, backupKey, cron, digits, email, fourDigitsCode, hexadecimal, macAddress, phone, sixDigitsCode, spaces, url };
|
|
30
|
+
export { absoluteLinuxPath, alpha, alphanum, alphanumLowercase, alphanumSpacesDotsUnderscoreDash, alphanumUnderscoreDash, alphanumUnderscoreDollarDash, alphanumdash, alphanumdashdots, alphanumdashdotsorempty, alphanumdashdotsspaces, alphanumdashorempty, alphanumdashspaces, alphanumdots, ascii, backupKey, cron, digits, email, fourDigitsCode, hexadecimal, macAddress, phone, sixDigitsCode, spaces, url };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@scaleway/regex",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.1.0",
|
|
4
4
|
"description": "A small utility to use regex",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -18,5 +18,5 @@
|
|
|
18
18
|
"directory": "packages/regex"
|
|
19
19
|
},
|
|
20
20
|
"license": "MIT",
|
|
21
|
-
"gitHead": "
|
|
21
|
+
"gitHead": "64aa3fdb7907402a1d24de9d884e7fae321b10e5"
|
|
22
22
|
}
|