mozilla / mozilla/protocol

Consider replacing deprecated `clip`

Open
#1,100 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Bug :beetle:
Dominant language
SCSS
Stars
298
Forks
83
Avg merge
16h 48m
Merged PRs (30d)
1

Description

Description

The visually-hidden helper includes an outdated syntax of clip: rect() that may need replacing with some other clipping properties or maybe updating the helper to something more current overall.

Steps to reproduce

The next stylelint-config-standard-scss major version won't like it.

😭 /actions/runs/17982808350/job/51153182926 ✂️

Expected result

https://developer.mozilla.org/en-US/docs/Web/CSS/clip

Actual result

https://github.com/mozilla/protocol/blob/81e6c70430416c3cde7c088f74c0e9fb9e1500a4/assets/sass/protocol/includes/mixins/_utils.scss#L128-L133

Environment

This might be breaking of sorts, in case a consumer applies the mixin, but then e.g. redefines or undoes the visual hiding in some cases, changing the clip value there — so there might be a migration to the newer mixin content version necessary for them.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the visually-hidden helper in assets/sass/protocol/includes/mixins/_utils.scss at the referenced lines, then review the stylelint-config-standard-scss failure from the linked workflow. Check the linked Mozilla bedrock usages for assumptions about the current clip value. Done means the deprecated syntax is addressed, lint passes, and any consumer migration impact is documented.

Written by the indexing model from the issue text.

Assessment

Tech stack
scss
Domain
frontend
Issue type
Refactor
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.