Skip to content

Commit fb0a869

Browse files
committed
chore: wip
1 parent 8c81e8c commit fb0a869

File tree

14 files changed

+1403
-197
lines changed

14 files changed

+1403
-197
lines changed

storage/framework/core/actions/package.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,6 @@
5959
"@stacksjs/strings": "workspace:*",
6060
"@stacksjs/utils": "workspace:*",
6161
"@stacksjs/validation": "workspace:*",
62-
"markdown-it": "^14.1.0",
63-
"vue-component-meta": "^3.0.6"
62+
"markdown-it": "^14.1.0"
6463
}
6564
}

storage/framework/core/faker/build.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ const result = await Bun.build({
1212
target: 'bun',
1313
// sourcemap: 'linked',
1414
minify: true,
15-
external: ['@stacksjs/cli'],
1615
plugins: [
1716
dts({
1817
root: '.',

storage/framework/core/faker/package.json

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -35,13 +35,10 @@
3535
"test": "bun test",
3636
"prepublishOnly": "bun run build"
3737
},
38-
"dependencies": {
39-
"ts-mocker": "^0.1.4"
40-
},
4138
"devDependencies": {
42-
"@faker-js/faker": "^9.9.0",
4339
"@stacksjs/cli": "workspace:*",
4440
"@stacksjs/config": "workspace:*",
45-
"@stacksjs/development": "workspace:*"
41+
"@stacksjs/development": "workspace:*",
42+
"ts-mocker": "^0.1.4"
4643
}
4744
}

storage/framework/core/query-builder/package.json

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -37,11 +37,6 @@
3737
"devDependencies": {
3838
"@stacksjs/database": "workspace:*",
3939
"@stacksjs/development": "workspace:*",
40-
"@stacksjs/types": "workspace:*",
41-
"@types/pg": "^8.15.5",
42-
"kysely": "^0.28.5",
43-
"kysely-bun-worker": "^0.7.0",
44-
"mysql2": "^3.14.3",
45-
"pg": "^8.16.3"
40+
"@stacksjs/types": "workspace:*"
4641
}
4742
}

storage/framework/core/strings/package.json

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,6 @@
5555
"devDependencies": {
5656
"@stacksjs/alias": "workspace:*",
5757
"@stacksjs/development": "workspace:*",
58-
"@stacksjs/types": "workspace:*",
59-
"@types/validator": "^13.15.3",
60-
"macroable": "^7.0.2",
61-
"validator": "^13.15.15"
58+
"@stacksjs/types": "workspace:*"
6259
}
6360
}
Lines changed: 5 additions & 169 deletions
Original file line numberDiff line numberDiff line change
@@ -1,170 +1,6 @@
1-
import type { HashAlgorithm } from '@stacksjs/types'
2-
import validator from 'validator'
1+
/**
2+
* String validation utilities
3+
* Re-exports from native validators
4+
*/
35

4-
export function isEmail(email: string): boolean {
5-
return validator.isEmail(email)
6-
}
7-
8-
export function isStrongPassword(password: string): boolean {
9-
return validator.isStrongPassword(password)
10-
}
11-
12-
export function isAlphanumeric(username: string): boolean {
13-
return validator.isAlphanumeric(username)
14-
}
15-
16-
export function validateUsername(username: string): boolean {
17-
return isAlphanumeric(username)
18-
}
19-
20-
export function isURL(url: string): boolean {
21-
return validator.isURL(url)
22-
}
23-
24-
export function isMobilePhone(phoneNumber: string): boolean {
25-
return validator.isMobilePhone(phoneNumber)
26-
}
27-
28-
export function isAlpha(name: string): boolean {
29-
return validator.isAlpha(name)
30-
}
31-
32-
export function isPostalCode(zipCode: string): boolean {
33-
return validator.isPostalCode(zipCode, 'any')
34-
}
35-
36-
export function isNumeric(number: string): boolean {
37-
return validator.isNumeric(number)
38-
}
39-
40-
export function isHexColor(color: string): boolean {
41-
return validator.isHexColor(color)
42-
}
43-
44-
export function isHexadecimal(hex: string): boolean {
45-
return validator.isHexadecimal(hex)
46-
}
47-
48-
export function isBase64(base64: string): boolean {
49-
return validator.isBase64(base64)
50-
}
51-
52-
export function isUUID(uuid: string): boolean {
53-
return validator.isUUID(uuid)
54-
}
55-
56-
export function isJSON(json: string): boolean {
57-
return validator.isJSON(json)
58-
}
59-
60-
export function isCreditCard(creditCard: string): boolean {
61-
return validator.isCreditCard(creditCard)
62-
}
63-
64-
export function isISBN(isbn: string): boolean {
65-
return validator.isISBN(isbn)
66-
}
67-
68-
export function isIP(ip: string): boolean {
69-
return validator.isIP(ip)
70-
}
71-
72-
export function isIPRange(ip: string): boolean {
73-
return validator.isIPRange(ip)
74-
}
75-
76-
export function isMACAddress(macAddress: string): boolean {
77-
return validator.isMACAddress(macAddress)
78-
}
79-
80-
export function isLatLong(latitude: string): boolean {
81-
return validator.isLatLong(latitude)
82-
}
83-
84-
export function isLatitude(longitude: string): boolean {
85-
return validator.isLatLong(longitude)
86-
}
87-
88-
export function isLongitude(longitude: string): boolean {
89-
return validator.isLatLong(longitude)
90-
}
91-
92-
export function isCurrency(currency: string): boolean {
93-
return validator.isCurrency(currency)
94-
}
95-
96-
export function isDataURI(dataURI: string): boolean {
97-
return validator.isDataURI(dataURI)
98-
}
99-
100-
export function isMimeType(mimeType: string): boolean {
101-
return validator.isMimeType(mimeType)
102-
}
103-
104-
export function isJWT(jwt: string): boolean {
105-
return validator.isJWT(jwt)
106-
}
107-
108-
export function isAscii(ascii: string): boolean {
109-
return validator.isAscii(ascii)
110-
}
111-
112-
export function isBase32(base32: string): boolean {
113-
return validator.isBase32(base32)
114-
}
115-
116-
export function isByteLength(byteLength: string): boolean {
117-
return validator.isByteLength(byteLength)
118-
}
119-
120-
export function isFQDN(fqdn: string): boolean {
121-
return validator.isFQDN(fqdn)
122-
}
123-
124-
export function isFullWidth(fullWidth: string): boolean {
125-
return validator.isFullWidth(fullWidth)
126-
}
127-
128-
export function isHalfWidth(halfWidth: string): boolean {
129-
return validator.isHalfWidth(halfWidth)
130-
}
131-
132-
export function isHash(hash: string, algorithm: HashAlgorithm): boolean {
133-
return validator.isHash(hash, algorithm)
134-
}
135-
136-
export function isHSL(hsl: string): boolean {
137-
return validator.isHSL(hsl)
138-
}
139-
140-
export function isIBAN(iban: string): boolean {
141-
return validator.isIBAN(iban)
142-
}
143-
144-
export function isIdentityCard(identityCard: string): boolean {
145-
return validator.isIdentityCard(identityCard)
146-
}
147-
148-
export function isISIN(isin: string): boolean {
149-
return validator.isISIN(isin)
150-
}
151-
152-
export function isISO8601(iso8601: string): boolean {
153-
return validator.isISO8601(iso8601)
154-
}
155-
156-
export function isISRC(isrc: string): boolean {
157-
return validator.isISRC(isrc)
158-
}
159-
160-
export function isISSN(issn: string): boolean {
161-
return validator.isISSN(issn)
162-
}
163-
164-
export function isISO31661Alpha2(iso31661Alpha2: string): boolean {
165-
return validator.isISO31661Alpha2(iso31661Alpha2)
166-
}
167-
168-
export function isISO31661Alpha3(iso31661Alpha3: string): boolean {
169-
return validator.isISO31661Alpha3(iso31661Alpha3)
170-
}
6+
export * from './validators'

storage/framework/core/strings/src/string.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,4 @@ export * from './macro'
44
export * from './pluralize'
55
export * from './slug'
66
export * from './utils'
7+
export * from './validators'

0 commit comments

Comments
 (0)