U.S. President Donald Trump's approval of a bill in support of Hong Kong's pro-democracy protesters may force Japan to reconsider whether it will really invite Chinese President Xi Jinping as a state guest next spring.

As political unrest in Hong Kong has continued unabated and China has shown no sign of acceding to protesters' demands, some conservative Japanese lawmakers have urged Prime Minister Shinzo Abe to rescind the invitation to Xi.

A Japanese government source also said Abe, who has tried to build a personal rapport with Trump, could struggle to obtain U.S. understanding about Xi's state visit to Japan, at a time when Washington and Beijing are divided over trade and security issues.

"Relations between Japan and China have been certainly improving, but they are still fragile," the source said, adding, "Possible U.S. involvement in Hong Kong would further complicate Japan's stance on how to get along with China."

"If the mainland China takes radical actions to clamp down on protests in Hong Kong, the (Japanese) government might be compelled to suspend President Xi's planned visit to Japan," the source said.

On Wednesday, Trump signed the Hong Kong Human Rights and Democracy Act, further worsening ties between the governments of world's biggest economies that have been engaged in a prolonged tit-for-tat tariff trade dispute.

The new law directs the State Department to conduct an annual review to certify whether Hong Kong is sufficiently autonomous to justify special treatment for bilateral agreements and programs.

A 1992 U.S. law gives Hong Kong a special status separate from the rest of mainland China with regard to tariffs and visa restrictions.

The newly enacted law includes a policy of coordination with allies such as Japan and South Korea "to promote democracy and human rights in Hong Kong."

Trump said he signed the bill "in the hope that leaders and representatives of China and Hong Kong will be able to amicably settle their differences, leading to long term peace and prosperity for all." Beijing has reacted harshly against his move.

Sino-Japanese ties, meanwhile, have often been strained over wartime history and territorial rows, but the two neighbors now describe their relations as having "returned to a normal track" as they have encouraged reciprocal visits by their leaders.

Beijing has been eager to deepen economic cooperation with Japan, given that the world's second-largest economy has been slowing down against a backdrop of the trade war with the United States, pundits say.

Tokyo and Beijing have agreed to work on preparations for Xi's visit to Japan as a state guest, with Abe inviting the Chinese president to come "when the cherry blossoms bloom."

Japanese Chief Cabinet Secretary Yoshihide Suga, the top government spokesman, said at a press conference on Thursday in Tokyo that he does not expect that the U.S. enactment of the Hong Kong human rights law will affect Xi's visit.

Victor Teo, an expert on East Asian affairs at the University of Hong Kong, said, "Having good and strong relations with China and the United States simultaneously is the best thing Japan can hope for."

Reflecting a thaw in ties between the two countries, China in mid-November freed a detained Japanese scholar who it claimed was spying during his visit to the nation in September.

On Nov. 15, Japanese Foreign Minister Toshimitsu Motegi told reporters that the detention of the professor at Hokkaido University was one of the matters of bilateral concern that Japan wanted to resolve to create a "good environment" to receive Xi.

But some Japanese lawmakers -- among whom are members of the ruling Liberal Democratic Party led by Abe -- have brazenly started to cast doubt on whether the government should accept Xi's visit as a state guest.

Earlier this month, a conservative group of the LDP called on Abe's office not to invite Xi to Japan, saying in a statement, "We cannot say that Japan-China relations have been on a normal track."

Especially after pro-democracy parties scored a landslide victory in Sunday's district council elections in Hong Kong, criticism against China's Communist Party has grown across the globe, making it "more difficult for Japan to welcome Xi," the source said.

Masahisa Sato, an LDP lawmaker who served as senior vice foreign minister under the Abe administration for around two years until September, has said in a Twitter post, "Can we welcome (Xi) as a guest to the emperor?"

Toru Kurata, a professor of Chinese politics at Rikkyo University in Tokyo said, "As President Xi has maintained a hardline approach toward Hong Kong, more Japanese citizens may have questions about whether Japan will invite him as a state guest."

Related coverage:

Police team enters besieged Hong Kong university campus

Japan's PM Abe urges China to maintain free and open Hong Kong