@lit/context
Advanced tools
Comparing version 1.0.0-pre.0 to 1.0.0
@@ -47,3 +47,3 @@ /** | ||
type ProvideDecorator<ContextType> = { | ||
<K extends PropertyKey, Proto extends ReactiveElement>(protoOrDescriptor: Proto, name?: K): FieldMustMatchContextType<Proto, K, ContextType>; | ||
<K extends PropertyKey, Proto extends Interface<ReactiveElement>>(protoOrDescriptor: Proto, name?: K): FieldMustMatchContextType<Proto, K, ContextType>; | ||
<C extends Interface<ReactiveElement>, V extends ContextType>(value: ClassAccessorDecoratorTarget<C, V>, context: ClassAccessorDecoratorContext<C, V>): void; | ||
@@ -50,0 +50,0 @@ }; |
@@ -47,3 +47,3 @@ /** | ||
type ProvideDecorator<ContextType> = { | ||
<K extends PropertyKey, Proto extends ReactiveElement>(protoOrDescriptor: Proto, name?: K): FieldMustMatchContextType<Proto, K, ContextType>; | ||
<K extends PropertyKey, Proto extends Interface<ReactiveElement>>(protoOrDescriptor: Proto, name?: K): FieldMustMatchContextType<Proto, K, ContextType>; | ||
<C extends Interface<ReactiveElement>, V extends ContextType>(value: ClassAccessorDecoratorTarget<C, V>, context: ClassAccessorDecoratorContext<C, V>): void; | ||
@@ -50,0 +50,0 @@ }; |
{ | ||
"name": "@lit/context", | ||
"version": "1.0.0-pre.0", | ||
"version": "1.0.0", | ||
"description": "Helpers and controllers for using Context protocol", | ||
@@ -167,4 +167,4 @@ "license": "BSD-3-Clause", | ||
"dependencies": { | ||
"@lit/reactive-element": "^2.0.0-pre.1", | ||
"lit": "^3.0.0-pre.1" | ||
"@lit/reactive-element": "^1.6.2 || ^2.0.0", | ||
"lit": "^2.7.5 || ^3.0.0" | ||
}, | ||
@@ -171,0 +171,0 @@ "devDependencies": { |
@@ -61,3 +61,3 @@ /** | ||
// Standard decorators branch | ||
nameOrContext.addInitializer(function (this: C) { | ||
nameOrContext.addInitializer(function (this: ReactiveElement) { | ||
controllerMap.set(this, new ContextProvider(this, {context})); | ||
@@ -130,3 +130,3 @@ }); | ||
// legacy | ||
<K extends PropertyKey, Proto extends ReactiveElement>( | ||
<K extends PropertyKey, Proto extends Interface<ReactiveElement>>( | ||
protoOrDescriptor: Proto, | ||
@@ -133,0 +133,0 @@ name?: K |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
205625
0