I have developed two unique Chrome extensions designed to enhance web pages with CSS and SVG filters. Here are the links to the source code:
CB Enhancer (adjusts colors for color-blind users) https://drive.google.com/open?id=1hvJIn3kPAMjaIWrAiUtIEVkEesQ1ce6W
CB Visualizer (simulates color blindness for web designers) https://drive.google.com/open?id=1_aHgNsLL2jam0pxmh7WuPSbIWBzIEjq0
Although the extensions serve different purposes, they share a similar implementation:
- Clicking a button triggers popup.js to communicate with background.js
- background.js then inserts or removes code (such as divs, styles, or SVG elements) based on the message received
However, I have noticed a discrepancy between CB Enhancer and CB Visualizer. While CB Enhancer instantly applies filters upon selection, CB Visualizer experiences a delay on certain websites like Facebook, requiring a scroll with the middle mouse button to activate the changes.
Both extensions alter the page's source code upon button press, but the delay is specific to CB Visualizer. If you have any insights on why this might be occurring, please share your knowledge.
Thank you!