Skip to content

This code handles checkbox interactions and prints to PDF

Notifications You must be signed in to change notification settings

erikkaincolor/printSearchPdf

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Twitter Badge Linkedin Badge Gmail Badge

printSearchPdf Feature

Tech Stack

I've developed a habit of prototyping certain software features and functionalities that I either need to learn for work or personal development. This #printSearchPdf is an instance of that. I wanted to play around with the PDF printJS library, implement JS, and practice toggle effects.

TL;DR:

  • Used a fastapi server framework
  • Implemented "Select All/Unselect All" functionality for checkboxes, improving the user experience.
  • Introduced a counter for selected items, providing users with instant feedback.
  • Implemented a print to pdf functionaily using printJS library.

In this repo...

Static > main.js, Lines 16-25: This code handles checkbox interactions. It checks that the "Select All" checkbox reflects the 'state' of individual checkboxes, providing an easy user experience. The code also keeps track of the selected items through a counter, updating dynamically as the user interacts with the checkboxes. This not only enhances the user experience but also gives transparency, allowing the user to know how many items they have selected.

This code uses event handling, where changes in checkboxes trigger specific cause/effect. It also includes DOM manipulation to update the state of checkboxes and the counter dynamically. Knowing how to implelement these on a small scale will help in my work projects and personal ones for overall responsive and user-friendly web applications, making the UI more engaging.

visitor badge

About

This code handles checkbox interactions and prints to PDF

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published