import { noChange } from 'lit'; import { AttributePart, Directive, DirectiveParameters, PartInfo } from 'lit/async-directive.js'; /** * A key-value set of class names to truthy values. */ export interface ShadowPartInfo { readonly [name: string]: string | boolean | number; } declare class ShadowPartMapDirective extends Directive { /** * Stores the ClassInfo object applied to a given AttributePart. * Used to unset existing values when a new ClassInfo object is applied. */ private _previousShadowParts?; private _staticShadowParts?; constructor(partInfo: PartInfo); render(shadowPartInfo: ShadowPartInfo): string; update(part: AttributePart, [shadowPartInfo]: DirectiveParameters): string | typeof noChange; } /** * A directive that applies dynamic shadow part names. * * This must be used in the `part` attribute and must be the only part used in * the attribute. It takes each property in the `shadowPartInfo` argument and adds * the property name to the element's `part` property if the property value is * truthy; if the property value is falsey, the property name is removed from * the element's `part`. * * For example `{foo: bar}` applies the part `foo` if the value of `bar` is * truthy. * * @param partMap */ export declare const partMap: (shadowPartInfo: ShadowPartInfo) => import('../../../node_modules/lit-html/node/directive.js').DirectiveResult; /** * The type of the class that powers this directive. Necessary for naming the * directive's return type. */ export type { ShadowPartMapDirective }; //# sourceMappingURL=shadow-part-map.d.ts.map