@tailwindcss/oxide 0.0.0-insiders.eb8d929 → 0.0.0-insiders.ec0049a
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/LICENSE +21 -0
- package/index.d.ts +23 -9
- package/index.js +63 -8
- package/package.json +33 -18
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) Tailwind Labs, Inc.
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/index.d.ts
CHANGED
|
@@ -4,20 +4,34 @@
|
|
|
4
4
|
/* auto-generated by NAPI-RS */
|
|
5
5
|
|
|
6
6
|
export interface ChangedContent {
|
|
7
|
+
/** File path to the changed file */
|
|
7
8
|
file?: string
|
|
9
|
+
/** Contents of the changed file */
|
|
8
10
|
content?: string
|
|
11
|
+
/** File extension */
|
|
9
12
|
extension: string
|
|
10
13
|
}
|
|
11
|
-
export interface
|
|
14
|
+
export interface GlobEntry {
|
|
15
|
+
/** Base path of the glob */
|
|
12
16
|
base: string
|
|
17
|
+
/** Glob pattern */
|
|
18
|
+
pattern: string
|
|
13
19
|
}
|
|
14
|
-
export
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
Parallel = 2
|
|
20
|
+
export interface ScannerOptions {
|
|
21
|
+
/** Glob sources */
|
|
22
|
+
sources?: Array<GlobEntry>
|
|
18
23
|
}
|
|
19
|
-
export
|
|
20
|
-
|
|
21
|
-
|
|
24
|
+
export interface CandidateWithPosition {
|
|
25
|
+
/** The candidate string */
|
|
26
|
+
candidate: string
|
|
27
|
+
/** The position of the candidate inside the content file */
|
|
28
|
+
position: number
|
|
29
|
+
}
|
|
30
|
+
export declare class Scanner {
|
|
31
|
+
constructor(opts: ScannerOptions)
|
|
32
|
+
scan(): Array<string>
|
|
33
|
+
scanFiles(input: Array<ChangedContent>): Array<string>
|
|
34
|
+
getCandidatesWithPositions(input: ChangedContent): Array<CandidateWithPosition>
|
|
35
|
+
get files(): Array<string>
|
|
36
|
+
get globs(): Array<GlobEntry>
|
|
22
37
|
}
|
|
23
|
-
export function parseCandidateStrings(input: Array<ChangedContent>, strategy: number): Array<string>
|
package/index.js
CHANGED
|
@@ -224,14 +224,72 @@ switch (platform) {
|
|
|
224
224
|
}
|
|
225
225
|
break
|
|
226
226
|
case 'arm':
|
|
227
|
+
if (isMusl()) {
|
|
228
|
+
localFileExisted = existsSync(
|
|
229
|
+
join(__dirname, 'tailwindcss-oxide.linux-arm-musleabihf.node')
|
|
230
|
+
)
|
|
231
|
+
try {
|
|
232
|
+
if (localFileExisted) {
|
|
233
|
+
nativeBinding = require('./tailwindcss-oxide.linux-arm-musleabihf.node')
|
|
234
|
+
} else {
|
|
235
|
+
nativeBinding = require('@tailwindcss/oxide-linux-arm-musleabihf')
|
|
236
|
+
}
|
|
237
|
+
} catch (e) {
|
|
238
|
+
loadError = e
|
|
239
|
+
}
|
|
240
|
+
} else {
|
|
241
|
+
localFileExisted = existsSync(
|
|
242
|
+
join(__dirname, 'tailwindcss-oxide.linux-arm-gnueabihf.node')
|
|
243
|
+
)
|
|
244
|
+
try {
|
|
245
|
+
if (localFileExisted) {
|
|
246
|
+
nativeBinding = require('./tailwindcss-oxide.linux-arm-gnueabihf.node')
|
|
247
|
+
} else {
|
|
248
|
+
nativeBinding = require('@tailwindcss/oxide-linux-arm-gnueabihf')
|
|
249
|
+
}
|
|
250
|
+
} catch (e) {
|
|
251
|
+
loadError = e
|
|
252
|
+
}
|
|
253
|
+
}
|
|
254
|
+
break
|
|
255
|
+
case 'riscv64':
|
|
256
|
+
if (isMusl()) {
|
|
257
|
+
localFileExisted = existsSync(
|
|
258
|
+
join(__dirname, 'tailwindcss-oxide.linux-riscv64-musl.node')
|
|
259
|
+
)
|
|
260
|
+
try {
|
|
261
|
+
if (localFileExisted) {
|
|
262
|
+
nativeBinding = require('./tailwindcss-oxide.linux-riscv64-musl.node')
|
|
263
|
+
} else {
|
|
264
|
+
nativeBinding = require('@tailwindcss/oxide-linux-riscv64-musl')
|
|
265
|
+
}
|
|
266
|
+
} catch (e) {
|
|
267
|
+
loadError = e
|
|
268
|
+
}
|
|
269
|
+
} else {
|
|
270
|
+
localFileExisted = existsSync(
|
|
271
|
+
join(__dirname, 'tailwindcss-oxide.linux-riscv64-gnu.node')
|
|
272
|
+
)
|
|
273
|
+
try {
|
|
274
|
+
if (localFileExisted) {
|
|
275
|
+
nativeBinding = require('./tailwindcss-oxide.linux-riscv64-gnu.node')
|
|
276
|
+
} else {
|
|
277
|
+
nativeBinding = require('@tailwindcss/oxide-linux-riscv64-gnu')
|
|
278
|
+
}
|
|
279
|
+
} catch (e) {
|
|
280
|
+
loadError = e
|
|
281
|
+
}
|
|
282
|
+
}
|
|
283
|
+
break
|
|
284
|
+
case 's390x':
|
|
227
285
|
localFileExisted = existsSync(
|
|
228
|
-
join(__dirname, 'tailwindcss-oxide.linux-
|
|
286
|
+
join(__dirname, 'tailwindcss-oxide.linux-s390x-gnu.node')
|
|
229
287
|
)
|
|
230
288
|
try {
|
|
231
289
|
if (localFileExisted) {
|
|
232
|
-
nativeBinding = require('./tailwindcss-oxide.linux-
|
|
290
|
+
nativeBinding = require('./tailwindcss-oxide.linux-s390x-gnu.node')
|
|
233
291
|
} else {
|
|
234
|
-
nativeBinding = require('@tailwindcss/oxide-linux-
|
|
292
|
+
nativeBinding = require('@tailwindcss/oxide-linux-s390x-gnu')
|
|
235
293
|
}
|
|
236
294
|
} catch (e) {
|
|
237
295
|
loadError = e
|
|
@@ -252,9 +310,6 @@ if (!nativeBinding) {
|
|
|
252
310
|
throw new Error(`Failed to load native binding`)
|
|
253
311
|
}
|
|
254
312
|
|
|
255
|
-
const {
|
|
313
|
+
const { Scanner } = nativeBinding
|
|
256
314
|
|
|
257
|
-
module.exports.
|
|
258
|
-
module.exports.IO = IO
|
|
259
|
-
module.exports.Parsing = Parsing
|
|
260
|
-
module.exports.parseCandidateStrings = parseCandidateStrings
|
|
315
|
+
module.exports.Scanner = Scanner
|
package/package.json
CHANGED
|
@@ -1,25 +1,33 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tailwindcss/oxide",
|
|
3
|
-
"version": "0.0.0-insiders.
|
|
3
|
+
"version": "0.0.0-insiders.ec0049a",
|
|
4
|
+
"repository": {
|
|
5
|
+
"type": "git",
|
|
6
|
+
"url": "git+https://github.com/tailwindlabs/tailwindcss.git",
|
|
7
|
+
"directory": "crates/node"
|
|
8
|
+
},
|
|
4
9
|
"main": "index.js",
|
|
5
10
|
"types": "index.d.ts",
|
|
6
11
|
"napi": {
|
|
7
12
|
"name": "tailwindcss-oxide",
|
|
8
13
|
"triples": {
|
|
9
14
|
"additional": [
|
|
15
|
+
"armv7-linux-androideabi",
|
|
16
|
+
"aarch64-linux-android",
|
|
10
17
|
"aarch64-apple-darwin",
|
|
11
18
|
"aarch64-unknown-linux-gnu",
|
|
12
19
|
"aarch64-unknown-linux-musl",
|
|
13
20
|
"armv7-unknown-linux-gnueabihf",
|
|
14
21
|
"x86_64-unknown-linux-musl",
|
|
15
22
|
"x86_64-unknown-freebsd",
|
|
16
|
-
"i686-pc-windows-msvc"
|
|
23
|
+
"i686-pc-windows-msvc",
|
|
24
|
+
"aarch64-pc-windows-msvc"
|
|
17
25
|
]
|
|
18
26
|
}
|
|
19
27
|
},
|
|
20
28
|
"license": "MIT",
|
|
21
29
|
"devDependencies": {
|
|
22
|
-
"@napi-rs/cli": "^2.
|
|
30
|
+
"@napi-rs/cli": "^2.18.4"
|
|
23
31
|
},
|
|
24
32
|
"engines": {
|
|
25
33
|
"node": ">= 10"
|
|
@@ -28,21 +36,28 @@
|
|
|
28
36
|
"index.js",
|
|
29
37
|
"index.d.ts"
|
|
30
38
|
],
|
|
31
|
-
"
|
|
32
|
-
"
|
|
33
|
-
"
|
|
34
|
-
"build:debug": "npx napi build --platform",
|
|
35
|
-
"version": "npx napi version"
|
|
39
|
+
"publishConfig": {
|
|
40
|
+
"provenance": true,
|
|
41
|
+
"access": "public"
|
|
36
42
|
},
|
|
37
43
|
"optionalDependencies": {
|
|
38
|
-
"@tailwindcss/oxide-
|
|
39
|
-
"@tailwindcss/oxide-
|
|
40
|
-
"@tailwindcss/oxide-freebsd-x64": "0.0.0-insiders.
|
|
41
|
-
"@tailwindcss/oxide-
|
|
42
|
-
"@tailwindcss/oxide-
|
|
43
|
-
"@tailwindcss/oxide-linux-arm64-
|
|
44
|
-
"@tailwindcss/oxide-linux-
|
|
45
|
-
"@tailwindcss/oxide-
|
|
46
|
-
"@tailwindcss/oxide-
|
|
44
|
+
"@tailwindcss/oxide-android-arm64": "0.0.0-insiders.ec0049a",
|
|
45
|
+
"@tailwindcss/oxide-linux-arm-gnueabihf": "0.0.0-insiders.ec0049a",
|
|
46
|
+
"@tailwindcss/oxide-freebsd-x64": "0.0.0-insiders.ec0049a",
|
|
47
|
+
"@tailwindcss/oxide-darwin-arm64": "0.0.0-insiders.ec0049a",
|
|
48
|
+
"@tailwindcss/oxide-darwin-x64": "0.0.0-insiders.ec0049a",
|
|
49
|
+
"@tailwindcss/oxide-linux-arm64-gnu": "0.0.0-insiders.ec0049a",
|
|
50
|
+
"@tailwindcss/oxide-linux-arm64-musl": "0.0.0-insiders.ec0049a",
|
|
51
|
+
"@tailwindcss/oxide-win32-x64-msvc": "0.0.0-insiders.ec0049a",
|
|
52
|
+
"@tailwindcss/oxide-linux-x64-musl": "0.0.0-insiders.ec0049a",
|
|
53
|
+
"@tailwindcss/oxide-win32-arm64-msvc": "0.0.0-insiders.ec0049a",
|
|
54
|
+
"@tailwindcss/oxide-linux-x64-gnu": "0.0.0-insiders.ec0049a"
|
|
55
|
+
},
|
|
56
|
+
"scripts": {
|
|
57
|
+
"artifacts": "napi artifacts",
|
|
58
|
+
"build": "napi build --platform --release --no-const-enum",
|
|
59
|
+
"dev": "cargo watch --quiet --shell 'npm run build'",
|
|
60
|
+
"build:debug": "napi build --platform --no-const-enum",
|
|
61
|
+
"version": "napi version"
|
|
47
62
|
}
|
|
48
|
-
}
|
|
63
|
+
}
|