It relates because the First Amendment to the U.S. Constitution is literally only a restriction on the federal government. It says:
Congress shall make no law respecting an establishment of religion, or prohibiting the free exercise thereof; or abridging the freedom of speech, or of the press; or the right of the people peaceably to assemble, and to petition the government for a redress of grievances.
U.S. Const. Amend 1 (Italics added). So originally it was only Congress (the federal government) that was prohibited from interfering with freedom of religion, free speech and free press, the right to assemble and the right to petition the government.
However, with the adoption of the 14th Amendment, which is an amendment directed at the States, the Supreme Court has held that most of the rights guaranteed to citizens in the federal Constitution also apply to the states. So when litigating a free speech case against a state or local government, the lawyer for the plaintiff will invoke the 14th Amendment as the basis for applying the First Amendment to the state before going on to discuss the First Amendment itself.

