@stacksjs/ts-css 0.1.0 → 0.1.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/CHANGELOG.md +51 -0
- package/dist/index.d.ts +12 -12
- package/dist/index.js +57 -7831
- package/dist/optimize/clean/comment.d.ts +1 -1
- package/dist/optimize/clean/declaration.d.ts +1 -1
- package/dist/optimize/compress/color.d.ts +5 -0
- package/dist/optimize/compress/index.d.ts +1 -1
- package/dist/optimize/compress/number.d.ts +9 -0
- package/dist/optimize/index.d.ts +2 -2
- package/dist/optimize/index.js +1 -3389
- package/dist/optimize/minify.d.ts +1 -1
- package/dist/optimize/specificity.d.ts +2 -2
- package/dist/parse/index.d.ts +1 -1
- package/dist/parse/index.js +1 -2368
- package/dist/select/attributes.d.ts +3 -0
- package/dist/select/general.d.ts +6 -0
- package/dist/select/helpers/always-true.d.ts +6 -0
- package/dist/select/helpers/querying.d.ts +10 -0
- package/dist/select/index.d.ts +1 -1
- package/dist/select/index.js +1 -1288
- package/dist/select/pseudo-selectors/index.d.ts +10 -0
- package/dist/select/pseudo-selectors/selectors.d.ts +4 -0
- package/dist/what/index.js +1 -513
- package/package.json +6 -7
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import type { AttributeSelectorNode } from '../what/index';
|
|
2
|
+
import type { CompiledQuery, Options } from './types';
|
|
3
|
+
export declare function compileAttribute<Node, ElementNode extends Node>(selector: AttributeSelectorNode, options: Options<Node, ElementNode>, next: CompiledQuery<ElementNode>): CompiledQuery<ElementNode>;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { ALWAYS_TRUE } from './helpers/always-true';
|
|
2
|
+
import type { CompiledQuery, Options } from './types';
|
|
3
|
+
import type { Selector } from '../what/index';
|
|
4
|
+
export declare function compileToken<Node, ElementNode extends Node>(token: Selector, options: Options<Node, ElementNode>, next: Compiled<ElementNode>): Compiled<ElementNode>;
|
|
5
|
+
declare type Compiled<E> = CompiledQuery<E>;
|
|
6
|
+
export { ALWAYS_TRUE };
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { Adapter, CompiledQuery } from '../types';
|
|
2
|
+
export declare function findAll<Node, ElementNode extends Node>(query: CompiledQuery<ElementNode>, nodes: ReadonlyArray<Node>, adapter: Adapter<Node, ElementNode>, xmlMode: boolean): ElementNode[];
|
|
3
|
+
export declare function findOne<Node, ElementNode extends Node>(query: CompiledQuery<ElementNode>, nodes: ReadonlyArray<Node>, adapter: Adapter<Node, ElementNode>, xmlMode: boolean): ElementNode | null;
|
|
4
|
+
/**
|
|
5
|
+
* Convert the user-supplied root into a search context. Mirrors
|
|
6
|
+
* `css-select`'s `prepareContext` — a single root node is replaced by its
|
|
7
|
+
* children (so the root itself isn't a candidate); arrays go through
|
|
8
|
+
* `removeSubsets` to avoid testing nested selections twice.
|
|
9
|
+
*/
|
|
10
|
+
export declare function prepareContext<Node, ElementNode extends Node>(elements: Node | Node[], adapter: Adapter<Node, ElementNode>): ReadonlyArray<Node>;
|
package/dist/select/index.d.ts
CHANGED