Pular para o conteúdo

STYLE_REFERENCE_UNDECLARED: CSS uses an undeclared variable or part

Este conteúdo não está disponível em sua língua ainda.

Severity Fault Stage
error customer (the source package) component declaration

A stylesheet of the component reads a CSS variable (var(--name)) that the manifest’s cssVars does not declare and the component’s CSS does not define, or names a part (::part(name), [part=name]) that parts does not declare. The declared variables and parts are the component’s whole styling API for the host page, so the build refuses names outside them. Usual causes: a typo, a missing prefix, or a variable used before it was added to cssVars.

Use a name the manifest declares, or declare it: a variable in cssVars (with a type and a default), a part in parts.