test(KB-301): fix mobile CSS test — make regex more specific to match bare textarea selector

This commit is contained in:
gsxdsm
2026-03-31 11:21:39 -07:00
parent dfb0f9198b
commit 30f822e776

View File

@@ -45,7 +45,8 @@ describe("mobile planning input font size CSS", () => {
it("only targets planning mode textareas, not all textareas globally", () => {
// The selector should specifically target .planning-textarea
// not a global textarea selector that would affect all textareas
const globalTextareaPattern = /@media[^{]*max-width[^}]*\{[^}]*textarea\s*\{[^}]*font-size:\s*16px/s;
// Match bare textarea selector (not .something-textarea)
const globalTextareaPattern = /@media[^{]*max-width[^}]*\{[^}]*\stextarea\s*\{[^}]*font-size:\s*16px/s;
expect(css).not.toMatch(globalTextareaPattern);
});