LP#1850547: new Angular file-reader component
authorGalen Charlton <gmc@equinoxinitiative.org>
Fri, 8 Nov 2019 23:39:34 +0000 (18:39 -0500)
committerGalen Charlton <gmc@equinoxinitiative.org>
Tue, 25 Aug 2020 16:23:38 +0000 (12:23 -0400)
commitecdc294da8279f6e804c1e977c98b578b3573fd6
tree00c7101015a2a9a5873b38c9e6423a40f8c865cb
parentf7450e06f682be0fe539a6106dba4b2bfc423569
LP#1850547: new Angular file-reader component

This adds a ControlValueAccessor wrapper around a file
reader form input. Any file loaded via that input is interpreted
as a text file whose lines are to be split into an array on
newlines, with leading and trailng whitespace removed.

Usage is:

<eg-file-reader [(ngModel)]="fileContents">
</eg-file-reader>

Sponsored-by: Evergreen Community Development Initiative
Sponsored-by: Georgia Public Library Service
Sponsored-by: Indiana State Library
Sponsored-by: C/W MARS
Signed-off-by: Galen Charlton <gmc@equinoxinitiative.org>
Open-ILS/src/eg2/src/app/share/common-widgets.module.ts
Open-ILS/src/eg2/src/app/share/file-reader/file-reader.component.html [new file with mode: 0644]
Open-ILS/src/eg2/src/app/share/file-reader/file-reader.component.ts [new file with mode: 0644]
Open-ILS/src/eg2/src/app/staff/sandbox/sandbox.component.html
Open-ILS/src/eg2/src/app/staff/sandbox/sandbox.component.ts