CHICAGO — Efforts to shrink collective bargaining rights for public workers in Wisconsin were slowed on Friday when a judge issued a temporary restraining order blocking a much-debated law from taking effect.

The decision, issued by Judge Maryann Sumi of the Dane County Circuit Court in Madison, temporarily bars the Wisconsin secretary of state from publishing the law, which limits bargaining to matters of wages. The fight over the law has drawn tens of thousands of demonstrators to the State Capitol, and the issue has become a focus of debate in numerous statehouses.

Publication of the law — a procedural requirement needed before it can take effect — had been expected next week. But Judge Sumi’s ruling could delay that until at least later in the month, when she plans to hold a full hearing on a lawsuit that accuses Republican lawmakers of violating the Wisconsin open meeting requirements to push through the bill. State officials said they were pursuing an appeal of the restraining order.

Reaction to the ruling offered more evidence that the rift over collective bargaining has not faded since Gov. Scott Walker, a Republican, signed the law a week ago. Democrats and union leaders said the decision would be the first of many that would ultimately be the policy’s undoing.