from static method

CSSFunction? from(
  1. Object? o
)
override

Implementation

static CSSFunction? from(Object? o) {
  if (o == null) return null;

  if (o is CSSCalc) {
    return o;
  } else if (o is CSSMax) {
    return o;
  } else if (o is CSSMin) {
    return o;
  } else if (o is String) {
    return CSSFunction.parse(o);
  }

  return null;
}