@archoleat/reglib 1.10.0 → 1.10.2
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/README.md +29 -0
- package/package.json +26 -31
package/README.md
CHANGED
|
@@ -8,6 +8,7 @@
|
|
|
8
8
|

|
|
9
9
|

|
|
10
10
|

|
|
11
|
+

|
|
11
12
|
|
|
12
13
|
## Table of Contents
|
|
13
14
|
|
|
@@ -135,6 +136,15 @@ bun i -D @archoleat/reglib
|
|
|
135
136
|
- Description: Matches a nested class selector.
|
|
136
137
|
- Example: Matches `&.class`, `&.my-class`.
|
|
137
138
|
|
|
139
|
+
- EMAIL_REGEX
|
|
140
|
+
|
|
141
|
+
- Pattern: `^[^\s@]+@[^\s@]+\.[^\s@]+$`.
|
|
142
|
+
|
|
143
|
+
- Description: Matches email addresses with basic validation.
|
|
144
|
+
|
|
145
|
+
- Example: Matches `user@example.com`, `test.email@domain.co.uk`,
|
|
146
|
+
but not `invalid@`, `@domain.com`, or `user@domain`.
|
|
147
|
+
|
|
138
148
|
- FONT_FILE_NAME_REGEX
|
|
139
149
|
|
|
140
150
|
- Pattern: A complex regex for matching font file names.
|
|
@@ -145,6 +155,25 @@ bun i -D @archoleat/reglib
|
|
|
145
155
|
- Example: Matches `Roboto-Bold.woff2`, `OpenSans-Italic-Variable.ttf`.
|
|
146
156
|
> More info [validate-font-file-name](https://github.com/archoleat/validate-font-file-name)
|
|
147
157
|
|
|
158
|
+
- IS_MOBILE_REGEX
|
|
159
|
+
|
|
160
|
+
- Pattern: `Mobi|iP(hone|od|ad)|Android|BlackBerry`.
|
|
161
|
+
|
|
162
|
+
- Description: Detects mobile devices based on user agent strings.
|
|
163
|
+
|
|
164
|
+
- Example: Matches `iPhone`, `iPad`, `Android`, `BlackBerry`,
|
|
165
|
+
`Mobile Safari`, but not `Windows`, `Macintosh`.
|
|
166
|
+
|
|
167
|
+
- NAME_REGEX
|
|
168
|
+
|
|
169
|
+
- Pattern: `^(?!-)[A-Za-z\u00C0-\u017FА-Яа-яЁё\s\-\u3000\u3040-\u309F\u30A0-\u30FF\u4E00-\u9FAF\u3400-\u4DBF]+(?<!-)$`.
|
|
170
|
+
|
|
171
|
+
- Description: Matches names with support for Latin, Cyrillic,
|
|
172
|
+
Japanese, and Chinese scripts. Cannot start or end with a hyphen.
|
|
173
|
+
|
|
174
|
+
- Example: Matches `John Doe`, `Jean-Paul`, `Иван Петров`,
|
|
175
|
+
`田中太郎`, but not `-John`, `Name-`, or `123`.
|
|
176
|
+
|
|
148
177
|
## Contributing
|
|
149
178
|
|
|
150
179
|
Please read [**CONTRIBUTING**](https://github.com/archoleat/.github/blob/main/CONTRIBUTING.md)
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@archoleat/reglib",
|
|
3
3
|
"description": "Library with ready-to-use regex",
|
|
4
|
-
"version": "1.10.
|
|
4
|
+
"version": "1.10.2",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": {
|
|
7
7
|
"email": "nikkeyl.me@gmail.com",
|
|
@@ -17,15 +17,10 @@
|
|
|
17
17
|
"url": "https://github.com/archoleat/reglib/issues"
|
|
18
18
|
},
|
|
19
19
|
"keywords": [
|
|
20
|
-
"archoleat-reglib",
|
|
21
20
|
"archoleat",
|
|
22
|
-
"library",
|
|
23
|
-
"plugin",
|
|
24
21
|
"ready-to-use",
|
|
25
22
|
"regex",
|
|
26
|
-
"
|
|
27
|
-
"regular-expression",
|
|
28
|
-
"regular-expressions"
|
|
23
|
+
"typescript"
|
|
29
24
|
],
|
|
30
25
|
"engines": {
|
|
31
26
|
"bun": ">=1.0.0"
|
|
@@ -47,42 +42,42 @@
|
|
|
47
42
|
"init": "bun i && husky"
|
|
48
43
|
},
|
|
49
44
|
"devDependencies": {
|
|
50
|
-
"@archoleat/commitlint-define-config": "^1.1.
|
|
51
|
-
"@archoleat/prettier-define-config": "^1.2.
|
|
52
|
-
"@archoleat/semantic-release-define-config": "^1.3.
|
|
53
|
-
"@commitlint/cli": "^
|
|
54
|
-
"@commitlint/config-conventional": "^
|
|
55
|
-
"@commitlint/types": "^
|
|
45
|
+
"@archoleat/commitlint-define-config": "^1.1.2",
|
|
46
|
+
"@archoleat/prettier-define-config": "^1.2.2",
|
|
47
|
+
"@archoleat/semantic-release-define-config": "^1.3.2",
|
|
48
|
+
"@commitlint/cli": "^21.2.0",
|
|
49
|
+
"@commitlint/config-conventional": "^21.2.0",
|
|
50
|
+
"@commitlint/types": "^21.2.0",
|
|
56
51
|
"@rollup/plugin-alias": "^6.0.0",
|
|
57
|
-
"@rollup/plugin-typescript": "^12.
|
|
52
|
+
"@rollup/plugin-typescript": "^12.3.0",
|
|
58
53
|
"@semantic-release/changelog": "^6.0.3",
|
|
59
54
|
"@semantic-release/git": "^10.0.1",
|
|
60
|
-
"@types/bun": "^1.3.
|
|
61
|
-
"@typescript-eslint/eslint-plugin": "^8.
|
|
62
|
-
"@typescript-eslint/parser": "^8.
|
|
63
|
-
"conventional-changelog-conventionalcommits": "^9.1
|
|
64
|
-
"editorconfig-checker": "^
|
|
65
|
-
"eslint": "^
|
|
55
|
+
"@types/bun": "^1.3.14",
|
|
56
|
+
"@typescript-eslint/eslint-plugin": "^8.62.1",
|
|
57
|
+
"@typescript-eslint/parser": "^8.62.1",
|
|
58
|
+
"conventional-changelog-conventionalcommits": "^9.3.1",
|
|
59
|
+
"editorconfig-checker": "^7.0.0",
|
|
60
|
+
"eslint": "^10.6.0",
|
|
66
61
|
"eslint-config-prettier": "^10.1.8",
|
|
67
62
|
"eslint-define-config": "^2.1.0",
|
|
68
|
-
"eslint-import-resolver-typescript": "^4.4.
|
|
63
|
+
"eslint-import-resolver-typescript": "^4.4.5",
|
|
69
64
|
"eslint-plugin-import": "^2.32.0",
|
|
70
|
-
"eslint-plugin-simple-import-sort": "^
|
|
71
|
-
"eslint-plugin-unicorn": "^
|
|
72
|
-
"
|
|
73
|
-
"globals": "^16.3.0",
|
|
65
|
+
"eslint-plugin-simple-import-sort": "^13.0.0",
|
|
66
|
+
"eslint-plugin-unicorn": "^70.0.0",
|
|
67
|
+
"globals": "^17.7.0",
|
|
74
68
|
"husky": "^9.1.7",
|
|
75
|
-
"lint-staged": "^
|
|
76
|
-
"prettier": "^3.
|
|
69
|
+
"lint-staged": "^17.0.8",
|
|
70
|
+
"prettier": "^3.9.4",
|
|
77
71
|
"remark": "15.0.1",
|
|
78
72
|
"remark-cli": "^12.0.1",
|
|
79
73
|
"remark-preset-lint-consistent": "^6.0.1",
|
|
80
74
|
"remark-preset-lint-markdown-style-guide": "^6.0.1",
|
|
81
75
|
"remark-preset-lint-recommended": "^7.0.1",
|
|
82
|
-
"rollup": "^4.
|
|
83
|
-
"rollup-plugin-dts": "^6.
|
|
76
|
+
"rollup": "^4.62.2",
|
|
77
|
+
"rollup-plugin-dts": "^6.4.1",
|
|
84
78
|
"rollup-plugin-esbuild": "^6.2.1",
|
|
85
|
-
"semantic-release": "^25.0.
|
|
86
|
-
"tslib": "^2.8.1"
|
|
79
|
+
"semantic-release": "^25.0.5",
|
|
80
|
+
"tslib": "^2.8.1",
|
|
81
|
+
"typescript": "^6.0.2"
|
|
87
82
|
}
|
|
88
83
|
}
|