typograph-editor-documentation
    Preparing search index...

    Function plan_replacements

    • The substitute_font() calls for the chosen rows, and the rows that cannot be replaced. Several families may go to one target: that is the point (MyVivenda's Georgia, Helvetica and Lato all to a theme's FONT_4).

      ⚠️ A row whose TARGET is a family also being replaced in this OK is refused. substitute_font() matches references by uuid, so the calls would chain: "Georgia → Arial" leaves Georgia carrying Arial's uuid, and a later "Arial → Helvetica" sweeps Georgia into Helvetica too; a swap collapses both families onto one. Replacing into a family that is going away has no meaning to order around, so it is reported instead. family_of_uuid answers which family a target uuid is.

      Parameters

      • entries: font_handle_entry[]
      • choices: Map<string, string>
      • uuid_for_family: (family: string) => string
      • family_of_uuid: (uuid: string) => string = ...

      Returns {
          calls: { family: string; from: string; to: string }[];
          problems: { family: string; reason: string }[];
      }