Пример #1
0
  public boolean appendDeclaration(Declaration declaration) {
    cssOnly.appendIgnoreNull(declaration.getNameAsString());
    cssOnly.append(':');
    if (!isCompressing()) cssOnly.ensureSeparator();
    if (declaration.getExpression() != null) append(declaration.getExpression());

    if (shouldHaveSemicolon(declaration)) cssOnly.appendIgnoreNull(";");

    return true;
  }
Пример #2
0
  private boolean shouldHaveSemicolon(Declaration declaration) {
    if (null == declaration.getParent()
        || declaration.getParent().getType() != ASTCssNodeType.SUPPORTS_QUERY) return true;

    return false;
  }