class_docstr: Terminal color definition.
class_docstr_tok: ["Terminal","color","definition","."]
docstr: Create a Color number from it's 8-bit ansi number.
  
  Args:
      number (int): A number between 0-255 inclusive.
  
  Returns:
      Color: A new Color instance.
docstr_tok: ["Create","a","Color","number","from","it","'s","8-bit","ansi","number",".","Args",":","number","(","int",")",":","A","number","between","0-255","inclusive",".","Returns",":","Color",":","A","new","Color","instance","."]
code: def from_ansi(cls, number: int) -> "Color":
      """Create a Color number from it's 8-bit ansi number.
  
      Args:
          number (int): A number between 0-255 inclusive.
  
      Returns:
          Color: A new Color instance.
      """
      return cls(
          name=f"color({number})",
          type=(
              ColorType.STANDARD if number < 16 else ColorType.EIGHT_BIT
          ),
          number=number,
      )
  
imports: import platform
  import re
  from colorsys import rgb_to_hls
  from enum import IntEnum
  from functools import lru_cache
  from typing import TYPE_CHECKING, NamedTuple, Optional, Tuple
  from ._palettes import EIGHT_BIT_PALETTE, STANDARD_PALETTE, WINDOWS_PALETTE
  from .color_triplet import ColorTriplet
  from .repr import Result, rich_repr
  from .terminal_theme import DEFAULT_TERMINAL_THEME
label_desc: Use image node_id 7 for calling the Color obj's underlying member method code with example usage: obj.from_ansi(cls, number) and returns: cls