Skip to content

Commit 924a833

Browse files
Browser Bookmarklet - Highlight mandatory fields on form (#1978)
* Create README.md * Create Highlight mandatory fields on form.js * Update README.md * Update Highlight mandatory fields on form.js Fixed issues in code
1 parent 2c8e071 commit 924a833

File tree

2 files changed

+25
-0
lines changed

2 files changed

+25
-0
lines changed

Specialized Areas/Browser Bookmarklets/Highlight Mandatory fields on form/Highlight mandatory fields on form.js

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
## Highlight Mandatory Fields
2+
3+
**Description**
4+
- This bookmarklet visually highlights all mandatory fields on a ServiceNow form by adding a glowing border or background around them.
5+
- It helps developers, admins, or QA testers quickly see which fields are marked as mandatory.
6+
- It also helps partial visually paired people to find the mandatory fields instead of looking for small * icon for field.
7+
- This works as a toggle. One click highlights the mandatory fields and clicking again removes the highlight.
8+
9+
**Example :**
10+
11+
- When activated on a form (e.g. Incident, Request Item):
12+
- Mandatory fields like Short description, Caller, etc get a soft glowing yellow border.
13+
- Click again → glow is removed.
14+
15+
**How it works:**
16+
- Detects `g_form` context.
17+
- Adds a temporary CSS class (`.mandatory-glow`) to all mandatory fields.
18+
- Click again to remove the highlights.
19+
20+
**Sample screenshot**
21+
<img width="1882" height="674" alt="image" src="https://github.com/user-attachments/assets/1320c9c3-976d-4bf0-92d5-e051825dbe6c" />
22+
23+
24+

0 commit comments

Comments
 (0)