[Geomoose-users] adding examples to our searches

Christopher Hughes chughes at co.lincoln.or.us
Mon Feb 28 15:00:50 PST 2022


I don't think this is currently an option, though I think it's definitely a
good idea.

I think I figured out a way to do this, though I needed to edit the source
code and rebuild the javascript.

I added a line of code at line 74 of text.js
<https://github.com/geomoose/gm3/blob/main/src/gm3/components/serviceInputs/text.js>
(note
that I named it 'example'):

            <div className='service-input'>
                <label htmlFor={ 'input-' + id }>{ this.props.field.label }
</label>
                <example htmlFor={ 'input-' + id }>{
this.props.field.example }</example>
                <input onChange={this.onChange} value={this.state.value}
type="text" id={ 'input-' + id}></input>
            </div>

After rebuilding the javascript I was then able to add examples to searches
in the app.js file:

            {type: 'text', label: 'Owner Name', example: '(i.e. Hughes)',
name: 'OwnName'},
            {type: 'text', label: 'Situs Address', example: '(i.e. 10770
ELK CITY RD)', name: 'SitusAll'},
            {type: 'text', label: 'Map Taxlot', example: '(i.e.
11-10-00-00-00300-00)', name: 'ParcelID'},
            {type: 'text', label: 'Account Number', name: 'PropertyId'}

You can then modify your site.css to decrease the size.

This was my end result:

[image: image.png]

Hope this helps,

Chris



On Thu, Feb 10, 2022 at 5:46 AM Mark Volz <MarkVolz at co.lyon.mn.us> wrote:

> Hello,
>
>
>
> I can change the titles for each field in the search tool.  Is it possible
> to add a line under the title that has an example of the search.  For
> Example:
>
>
>
> On the first line with the current font : “Parcel ID”
>
> On the next line with a smaller font: “Example 01-001001-0”
>
>
>
> This will help users understand which format they should use when they
> perform a search.
>
>
>
> Thank You!
>
>
>
> Sincerely,
>
> *Mark Volz, GISP*
>
> *Lyon County GIS Coordinator*
>
> Ph:  (507) 532-8218
>
>
> _______________________________________________
> Geomoose-users mailing list
> Geomoose-users at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/geomoose-users
>


-- 
Chris Hughes

GIS Analyst
Lincoln County Surveyor Department
880 NE 7th St. l Newport, OR 97365
Tel: (541) 574 1283
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/geomoose-users/attachments/20220228/88cd2dda/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image.png
Type: image/png
Size: 14395 bytes
Desc: not available
URL: <http://lists.osgeo.org/pipermail/geomoose-users/attachments/20220228/88cd2dda/attachment-0001.png>


More information about the Geomoose-users mailing list