The core sugya on economic competition, found in Bava Batra 21b:1 and codified in Shulchan Arukh, Choshen Mishpat 156:5 and Tur, Choshen Mishpat 156:10, establishes that a craftsman already settled in an alleyway cannot stop a new competitor from opening a rival business of the same kind, even a tailor, tanner, bathhouse, or mill, so long as the new entrant is a local resident; only an outsider coming from elsewhere may sometimes be blocked. Gray Matter I, Monetary Issues, Hasagat Gevul explains that the halacha follows the view that competition itself does not constitute forbidden encroachment, and concludes that the Shulchan Arukh's ruling in Choshen Mishpat 156:5 sanctions what amounts to nearly unrestricted free enterprise.
That general permission to compete, however, is distinct from the employee's obligations while still employed. Shulchan Arukh, Choshen Mishpat 331:1 rules that one who hires workers must follow the local custom regarding their hours and conduct, establishing that the employment relationship carries binding terms of service. Mishpetei Uziel, Volume IV, Choshen Mishpat 42:18 goes further, holding that a worker must regard his time, physical strength, and intellectual capacities during the hours of employment as subjugated to his employer's work, bringing the Gemara's account of Abba Chilkiya refusing to greet scholars because he was a hired day-laborer and may not be distracted, and ruling that a worker must devote his full energies to the employer's work during the term of hire.
Rav Eliezer Melamed (Peninei Halakhah, Likkutim II 4:14) extends this into concrete workplace cases, ruling that an employee at an office or factory must be careful of the prohibition of theft in the workplace, giving the example that using the employer's phone or resources beyond what is explicitly permitted — even in minor, seemingly harmless ways — constitutes forbidden use of the employer's property without permission.
The broader prohibition against theft, stated in Shulchan Arukh, Choshen Mishpat 348:1-2, holds that it is forbidden to steal anything of value, even a small amount, and even temporarily or playfully, so that a person does not become accustomed to such behavior; this underlies why using an employer's resources, time, or work product without permission is not a neutral act but falls under the same prohibition.
Shulchan Arukh, Choshen Mishpat 176:10 addresses a related principle in partnership law, ruling that a partner acting generally on behalf of a joint venture may not deviate from the accepted practice of that trade, may not go elsewhere with it, and may not take up a different trade without his partner's consent — reflecting the broader concern that one bound into a business relationship owes a duty of fidelity to its accepted scope and practices, a concern that resonates with the employee's duty described above.
Mishneh Torah, Human Dispositions 5:13-14 adds the ethical dimension that a person of good character should not descend into another's trade (אומנות) nor cause distress to another, counseling that one should be among the pursued rather than the pursuer — a value that bears on how an employee ought to conduct himself toward his employer even where strict law may permit competition.