Code Coverage
 
Lines
Functions and Methods
Classes and Traits
Total
n/a
0 / 0
n/a
0 / 0
CRAP
n/a
0 / 0
1<?php
2
3declare(strict_types=1);
4
5namespace Cosray\Richtext;
6
7use Cosray\Assets\Asset;
8
9/**
10 * Resolves the uid references a document carries while rendering:
11 * catalog assets (`image.uid`, `link.asset`), node URL paths
12 * (`link.node`), and locale maps such as catalog asset meta.
13 */
14interface Resolver
15{
16    public function asset(string $uid): ?Asset;
17
18    /** The referenced node's URL path for the current locale. */
19    public function nodePath(string $uid): ?string;
20
21    /** Resolve a locale map along the current locale fallback chain. */
22    public function localize(array $map): mixed;
23}