toggleAttribute method

void toggleAttribute(
  1. String attributeId
)

Implementation

void toggleAttribute(String attributeId) {
  final bool isCurrentlyEnabled = isAttributeEnabled(attributeId);
  setImportance(
    attributeId,
    isCurrentlyEnabled ? disabledImportanceId : enabledImportanceId,
  );
}