The issue of presidents and classified information is complicated.
The president is the ultimate authority of classification for all classified information generated by the US. He has what is called Original Classification Authority (OCA). Sometimes it is called original classifying authority.
The president can designate other US government officials with OCA. For example, the Secretary of State has OCA for all classified information originating from the Department of State, but not for information originating from, for example, the Department of Defense.
When an OCA determines that a piece of information is to be protected at a classification level (classification), at another classification (reclassification) or that the information is no longer classified (declassification), this decision has to be documented. Otherwise there is a real risk that different organizations will treat the same information at different levels.
One could make the argument that the PotUS ain't gonna do no documentation as he has people to do so. That is probably a viable viewpoint. I don't think anyone expects the PotUS to actually sit down and fill out the classification/reclassification/declassification paperwork. However, that means that the PotUS needs to coordinate his classification decision either before disclosure (best practice) or immediately after disclosure. In any case, the PotUS' classification decisions need to be documented.
A wise president would carefully coordinate classification decisions with the major stakeholders, but there is no legal requirement to do so. The president is the OCA for the United States and not just for the Executive Branch.
There are no federal laws that restrict the president's OCA concerning information whose classification originates from the United State's government. There are, however, policies that govern the OCA activity.
6 U.S. Code § 485 is a federal law that establishes policy for information sharing within the US and foreign governments but does not limit the president's OCA. 6 U.S. Code § 485 does not address classified information at all, but uses general terms such as "terrorism and homeland security information".
If, and this has not been demonstrated, Trump disclosed classified information to someone, he has not violated any federal law. He may have violated policy however. But Law and policy are two different things. If Trump did use his OCA in disclosing this information, there needs to be documentation of that classification decision. Again, that is policy not law.
All this applies to classified information that originates from the US.
One of the issues of the alleged action was that the disclosure involved information that was classified by another country and given to the US under an information sharing agreement. Some of these agreements are very sensitive. Rarely are they are governed by US federal law (especially the sensitive relationships). However, there are US policies governing how this information needs to be handled. There may be foreign laws involved, and most importantly, there are sensitive relationships that are formulated on mutual trust.
If, and this has not been demonstrated, Trump disclosed classified information that originated from a foreign government he has
1. Not violated any US federal law.
2. May have violated US policy.
3. May have violated the laws of the other country. Not that this matters much as the president is, for practical purposes, not bound by federal laws of other countries.
4. Probably violated the trust with regards to not only the country of agreement, but with other countries we have other agreements. If he violated the trust of country A, why would countries B-Z think he would not violate their trust.
Assuming that Trump did what he is being accused of, and that has not been settled. Trump has
Not broken any federal laws
Broken policy
Certainly adversely affected the level of trust in other nations.
My opinion: What he did was not illegal, but incredibly shortsighted and potentially harmful to the US' relationships of trust that will take years/decades to repair.