Socket
Socket
Sign inDemoInstall

@unocss/core

Package Overview
Dependencies
Maintainers
2
Versions
369
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@unocss/core - npm Package Compare versions

Comparing version 0.60.4 to 0.61.0

92

dist/index.d.ts

@@ -61,4 +61,4 @@ import { LoadConfigResult } from 'unconfig';

declare function normalizeCSSEntries(obj: string | CSSEntries | CSSObject): string | CSSEntries;
declare function normalizeCSSValues(obj: CSSValue | string | (CSSValue | string)[]): (string | CSSEntries)[];
declare function normalizeCSSEntries(obj: string | CSSEntriesInput | CSSObjectInput): string | CSSEntries;
declare function normalizeCSSValues(obj: CSSValueInput | string | (CSSValueInput | string)[]): (string | CSSEntries)[];
declare function clearIdenticalEntries(entry: CSSEntries): CSSEntries;

@@ -83,3 +83,2 @@ declare function entriesToCss(arr?: CSSEntries): string;

declare const validateFilterRE: RegExp;
declare const CONTROL_SHORTCUT_NO_MERGE = "$$shortcut-no-merge";
declare function isAttributifySelector(selector: string): RegExpMatchArray | null;

@@ -138,2 +137,3 @@ declare function isValidSelector(selector?: string): selector is string;

declare const symbols: ControlSymbols;
declare class UnoGenerator<Theme extends object = object> {

@@ -188,35 +188,7 @@ userConfig: UserConfig<Theme>;

type CSSObject = Record<string, string | number | undefined>;
type CSSEntries = [string, string | number | undefined][];
interface CSSColorValue {
type: string;
components: (string | number)[];
alpha: string | number | undefined;
}
type RGBAColorValue = [number, number, number, number] | [number, number, number];
interface ParsedColorValue {
/**
* Parsed color value.
*/
color?: string;
/**
* Parsed opacity value.
*/
opacity: string;
/**
* Color name.
*/
name: string;
/**
* Color scale, preferably 000 - 999.
*/
no: string;
/**
* {@link CSSColorValue}
*/
cssColor: CSSColorValue | undefined;
/**
* Parsed alpha value from opacity
*/
alpha: string | number | undefined;
}
type CSSEntry = [string, string | number | undefined];
type CSSEntries = CSSEntry[];
type CSSObjectInput = CSSObject | Partial<ControlSymbolsValue>;
type CSSEntriesInput = (CSSEntry | ControlSymbolsEntry)[];
type CSSValueInput = CSSObjectInput | CSSEntriesInput | CSSValue;
type PresetOptions = Record<string, any>;

@@ -238,2 +210,6 @@ interface RuleContext<Theme extends object = object> {

/**
* Symbols for special handling
*/
symbols: ControlSymbols;
/**
* The theme object

@@ -268,2 +244,34 @@ */

}
declare const SymbolShortcutsNoMerge: unique symbol;
declare const SymbolVariants: unique symbol;
declare const SymbolParent: unique symbol;
declare const SymbolSelector: unique symbol;
interface ControlSymbols {
/**
* Prevent merging in shortcuts
*/
shortcutsNoMerge: typeof SymbolShortcutsNoMerge;
/**
* Additional variants applied to this rule
*/
variants: typeof SymbolVariants;
/**
* Parent selector (`@media`, `@supports`, etc.)
*/
parent: typeof SymbolParent;
/**
* Selector modifier
*/
selector: typeof SymbolSelector;
}
interface ControlSymbolsValue {
[SymbolShortcutsNoMerge]: true;
[SymbolVariants]: VariantHandler[];
[SymbolParent]: string;
[SymbolSelector]: (selector: string) => string;
}
type ObjectToEntry<T> = {
[K in keyof T]: [K, T[K]];
}[keyof T];
type ControlSymbolsEntry = ObjectToEntry<ControlSymbolsValue>;
interface VariantContext<Theme extends object = object> {

@@ -350,3 +358,3 @@ /**

type CSSValues = CSSValue | CSSValue[];
type DynamicMatcher<Theme extends object = object> = ((match: RegExpMatchArray, context: Readonly<RuleContext<Theme>>) => Awaitable<CSSValue | string | (CSSValue | string)[] | undefined>);
type DynamicMatcher<Theme extends object = object> = (match: RegExpMatchArray, context: Readonly<RuleContext<Theme>>) => Awaitable<CSSValueInput | string | (CSSValueInput | string)[] | undefined> | Generator<CSSValueInput | string | undefined> | AsyncGenerator<CSSValueInput | string | undefined>;
type DynamicRule<Theme extends object = object> = [RegExp, DynamicMatcher<Theme>] | [RegExp, DynamicMatcher<Theme>, RuleMeta];

@@ -422,3 +430,3 @@ type StaticRule = [string, CSSObject | CSSEntries] | [string, CSSObject | CSSEntries, RuleMeta];

*/
matcher: string;
matcher?: string;
/**

@@ -714,2 +722,8 @@ * Order in which the variant is applied to selector.

envMode?: 'dev' | 'build';
/**
* legacy.renderModernChunks need to be consistent with @vitejs/plugin-legacy
*/
legacy?: {
renderModernChunks: boolean;
};
}

@@ -1017,2 +1031,2 @@ /**

export { type ArgumentType, type Arrayable, type AutoCompleteExtractor, type AutoCompleteExtractorContext, type AutoCompleteExtractorResult, type AutoCompleteFunction, type AutoCompleteTemplate, type Awaitable, BetterMap, type BlocklistMeta, type BlocklistRule, type BlocklistValue, CONTROL_SHORTCUT_NO_MERGE, type CSSColorValue, type CSSEntries, type CSSObject, type CSSValue, type CSSValues, type CliEntryItem, type CliOptions, type ConfigBase, type ContentOptions, CountableSet, type DeepPartial, type DynamicMatcher, type DynamicRule, type DynamicShortcut, type DynamicShortcutMatcher, type ExtendedTokenInfo, type Extractor, type ExtractorContext, type FilterPattern, type FlatObjectTuple, type GenerateOptions, type GenerateResult, type GeneratorOptions, type HighlightAnnotation, type OutputCssLayersOptions, type ParsedColorValue, type ParsedUtil, type PartialByKeys, type PluginOptions, type Postprocessor, type Preflight, type PreflightContext, type PreparedRule, type Preprocessor, type Preset, type PresetFactory, type PresetOptions, type PresetOrFactory, type RGBAColorValue, type RawUtil, type Replacement, type RequiredByKey, type ResolvedConfig, type RestArgs, type Rule, type RuleContext, type RuleMeta, type SafeListContext, type Shift, type Shortcut, type ShortcutValue, type SourceCodeTransformer, type SourceCodeTransformerEnforce, type SourceMap, type StaticRule, type StaticShortcut, type StaticShortcutMap, type StringifiedUtil, type SuggestResult, type ThemeExtender, type ToArray, TwoKeyMap, UnoGenerator, type UnocssPluginContext, type UserConfig, type UserConfigDefaults, type UserOnlyOptions, type UserShortcuts, type UtilObject, type Variant, type VariantContext, type VariantFunction, type VariantHandler, type VariantHandlerContext, type VariantMatchedResult, type VariantObject, attributifyRE, clearIdenticalEntries, clone, collapseVariantGroup, createGenerator, cssIdRE, defaultSplitRE, definePreset, e, entriesToCss, escapeRegExp, escapeSelector, expandVariantGroup, extractorSplit as extractorDefault, extractorSplit, hasScopePlaceholder, isAttributifySelector, isCountableSet, isObject, isRawUtil, isStaticRule, isStaticShortcut, isString, isValidSelector, makeRegexClassGroup, mergeConfigs, mergeDeep, noop, normalizeCSSEntries, normalizeCSSValues, normalizeVariant, notNull, parseVariantGroup, regexScopePlaceholder, resolveConfig, resolvePreset, resolvePresets, resolveShortcuts, splitWithVariantGroupRE, toArray, toEscapedSelector, uniq, uniqueBy, validateFilterRE, warnOnce, withLayer };
export { type ArgumentType, type Arrayable, type AutoCompleteExtractor, type AutoCompleteExtractorContext, type AutoCompleteExtractorResult, type AutoCompleteFunction, type AutoCompleteTemplate, type Awaitable, BetterMap, type BlocklistMeta, type BlocklistRule, type BlocklistValue, type CSSEntries, type CSSEntriesInput, type CSSEntry, type CSSObject, type CSSObjectInput, type CSSValue, type CSSValueInput, type CSSValues, type CliEntryItem, type CliOptions, type ConfigBase, type ContentOptions, type ControlSymbols, type ControlSymbolsEntry, type ControlSymbolsValue, CountableSet, type DeepPartial, type DynamicMatcher, type DynamicRule, type DynamicShortcut, type DynamicShortcutMatcher, type ExtendedTokenInfo, type Extractor, type ExtractorContext, type FilterPattern, type FlatObjectTuple, type GenerateOptions, type GenerateResult, type GeneratorOptions, type HighlightAnnotation, type ObjectToEntry, type OutputCssLayersOptions, type ParsedUtil, type PartialByKeys, type PluginOptions, type Postprocessor, type Preflight, type PreflightContext, type PreparedRule, type Preprocessor, type Preset, type PresetFactory, type PresetOptions, type PresetOrFactory, type RawUtil, type Replacement, type RequiredByKey, type ResolvedConfig, type RestArgs, type Rule, type RuleContext, type RuleMeta, type SafeListContext, type Shift, type Shortcut, type ShortcutValue, type SourceCodeTransformer, type SourceCodeTransformerEnforce, type SourceMap, type StaticRule, type StaticShortcut, type StaticShortcutMap, type StringifiedUtil, type SuggestResult, type ThemeExtender, type ToArray, TwoKeyMap, UnoGenerator, type UnocssPluginContext, type UserConfig, type UserConfigDefaults, type UserOnlyOptions, type UserShortcuts, type UtilObject, type Variant, type VariantContext, type VariantFunction, type VariantHandler, type VariantHandlerContext, type VariantMatchedResult, type VariantObject, attributifyRE, clearIdenticalEntries, clone, collapseVariantGroup, createGenerator, cssIdRE, defaultSplitRE, definePreset, e, entriesToCss, escapeRegExp, escapeSelector, expandVariantGroup, extractorSplit as extractorDefault, extractorSplit, hasScopePlaceholder, isAttributifySelector, isCountableSet, isObject, isRawUtil, isStaticRule, isStaticShortcut, isString, isValidSelector, makeRegexClassGroup, mergeConfigs, mergeDeep, noop, normalizeCSSEntries, normalizeCSSValues, normalizeVariant, notNull, parseVariantGroup, regexScopePlaceholder, resolveConfig, resolvePreset, resolvePresets, resolveShortcuts, splitWithVariantGroupRE, symbols, toArray, toEscapedSelector, uniq, uniqueBy, validateFilterRE, warnOnce, withLayer };
{
"name": "@unocss/core",
"type": "module",
"version": "0.60.4",
"version": "0.61.0",
"description": "The instant on-demand Atomic CSS engine.",

@@ -6,0 +6,0 @@ "author": "Anthony Fu <anthonyfu117@hotmail.com>",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc