refactor(cli-utils-image): rename render_image to render

This commit is contained in:
Benexl
2025-07-27 12:27:40 +03:00
parent a8f2579f82
commit 96233b14ff
2 changed files with 3 additions and 4 deletions

View File

@@ -1,7 +1,5 @@
from typing import Callable, Dict, Literal, Optional
from rich.console import Console
from .....libs.media_api.params import (
MediaAiringScheduleParams,
MediaCharactersParams,
@@ -256,6 +254,7 @@ def _view_info(ctx: Context, state: State) -> MenuAction:
from rich import box
from rich.columns import Columns
from rich.console import Console
from rich.panel import Panel
from rich.table import Table
from rich.text import Text
@@ -267,7 +266,7 @@ def _view_info(ctx: Context, state: State) -> MenuAction:
# Display cover image if available
if cover_image := media_item.cover_image:
image.render_image(cover_image.large)
image.render(cover_image.large)
# Create main title
main_title = (

View File

@@ -13,7 +13,7 @@ import httpx
logger = logging.getLogger(__name__)
def render_image(url: str, capture: bool = False, size: str = "30x30") -> Optional[str]:
def render(url: str, capture: bool = False, size: str = "30x30") -> Optional[str]:
"""
Renders an image from a URL in the terminal using icat or chafa.