Week Beginning 3rd June 2024

I returned to working on the Iona place-names interactive map this week, which I’d not worked on for a while.  The team had demonstrated the resource at an event last week and had a few suggestions after this.  They’d noticed that the map was rather cluttered on mobile devices with both the side panel and the map legend opened and I therefore added in a check for screen width when the page initially loads.  If the width is less than 500 pixels the legend is hidden by default, which stops multiple panels appearing and overlapping.  I decided against hiding the left panel as this might be more confusing as users will generally need to use this panel and if it’s off by default they might not realise it’s there.

I also made a couple of other tweaks.  Firstly, I’d noticed the ‘Select all’ option in the legend was remaining visible when the legend was hidden and I sorted this.  It was actually rather tricker than I’d expected to get this working but it’s sorted now.  I also replaced the ‘Show / Hide’ text that was the only text in the legend button to just display ‘Legend’ instead (along with the up/down icon).  I figured this would make it clearer what the section was when it’s hidden by default.  Secondly, the tabs in the record popup were overlapping on narrow screens when the tabs were split over two lines so I added a vertical margin to the tabs to fix this.  I don’t think there are any other issues with the layout on mobile devices, but I’ll just need to see if anything else gets reported.  Below is a screenshot of the map on a mobile device, showing the legend closed by default and the left-hand panel open:

I was also alerted to the fact that I hadn’t implemented the display of images associated with place-names yet so I implemented this.  I had to update the API to ensure image data was outputted and for places that have images the record popup now features an ‘Images’ tab.  Pressing on this displays the image and its caption, for example:

For the moment if there are multiple images for a place they will each appear in the tab, one after the other.  We might want to consider some sort of slideshow instead.  I also ensured that sounds associated with place-names are now also set to be returned by the API, but as of yet I haven’t added in a tab for them, as we don’t currently have any sounds in the system.

The team also wanted cross references between place-names to appear in the mini-popup in addition to the main one, so I added these in.  However, whilst working on this I realised there was a bit of a problem with how cross references were working:  The links would only work if the cross referenced place-name was also part of the currently visible map data.  For example, a quick search for ‘buaile’ results in only 6 matching place-names on the map.  The cross reference for ‘Buaile Staonaig’ is ‘Loch Staonaig’, which is not part of these results and therefore pressing on the cross reference wasn’t doing anything.  This was a bit of a headache to sort out, resulting in some pretty major changes to the code.

What happens now is if the cross referenced place is also on the map then clicking on the link will move you to it as you’d expect.  But if the place is not on the map then when you press on the link the map resets itself, loading in all place-name data.  Once the data is loaded in then the system identifies the cross referenced place and moves the map to it.  It’s maybe a bit confusing to have all of the data loading in, but I just couldn’t think of another way to do it without messing up the view of the map with place-names that don’t match the criteria.

Also this week I spent some time making final alterations to the websites for the three new Speak For Yersel regions.  This included adding in logos, replacing some of the images used in the surveys, adding in new questions and making tweaks to existing questions, adding in the ‘About’ pages and removing all of the test users and their data from the systems ahead of piloting.  The resources are ready to go now, although it’s likely that some further tweaks will be required after the piloting phase.

I also spent about a day further researching a new potential project on 18th and 19th century playbills for researcher Deven Parker.  I can’t really go into too much about this here, but there was a lot to consider and I sent a lengthy email to Deven containing many discussion points.

My other main task of the week was to investigate adding new texts to the ‘Textbase’ of the Anglo-Norman Dictionary (see https://anglo-norman.net/textbase-browse/).  Geert had sent me a new text for me to try and add to the resource and I spent some time working with it and the various import scripts that I’d created for the existing Textbase texts.

Unfortunately the structure of the new file is quite different to the existing XML files.  I was hoping I’d be able to just run the XML through the same scripts but this isn’t going to work without a lot of changes to the scripts.  There are no <pb> tags in the new file.  These are used to denote page breaks and are important for the search facilities, as words extracted for search purposes are associated with a page record in the system.  If having pages really doesn’t matter I can easily just add a <pb> around all of the text, which should sort the issue.  There may also be an issue with the ‘jump to page’ feature, which would of course only then contain one page.  Related to this, as there are no page breaks all notes will end up appearing at the very end of the text as technically there will be no ‘pages’.  The XML (which was generated using a tool called the Classical Text Editor) contains a lot of data relating to the style of elements (within <tagsDecl>) and a lot of the text is contained within <hi> tags, although it’s not clear why.  E.g. we have <hi rend=”font-size:12pt;”>Nous lisoms en anciens estories les uns avoir environee les provinces, et avoir alee as novels poeples, avoir passee les meers, q’eux verroient devaunt</hi> but in the PDF view of the text there is no discernible reason why ‘devaunt’ is the last word in this tag as the first word in the following tag (ycestes) follows directly on from it.  Also, the numbers at the start of paragraphs are not specifically marked up but are instead just part of the text, (e.g. <hi rend=”font-size:12pt;”>[1.1] Frere Ambros, a moi portaunt…).  This means we wouldn’t be able to separate out the numbers from the text or apply a different style to them.  There was also a lack of metadata about the text, and what was there was not in the same structure as in the existing textbase texts.

I suggested to the editor Geert that as the Classical Text Editor seems to add an awful lot of unnecessary (from our point of view) tags that result in a very messy XML file whether the texts could instead just be produced directly in Oxygen.  I spent a bit of time creating a sample XML document in Oxygen, including just the first few paragraphs of the text.

It seemed pretty feasible to me to create the texts in this fashion, but I did spot an issue.  The existing Textbase texts are not actually valid TEI XML.  The texts don’t link to a DTD or the TEI namespace and when I did try doing so with my sample file in Oxygen it produced a lot of errors.  E.g. the ‘fb’ element used for folio breaks in the Textbase texts is not a TEI element.  Unfortunately we’d need to conform to the old Textbase XML as that is what my processing scripts are set up to work with.  However, we’d have to end up with such non-valid (from a TEI point of view) XML in any case if we want to incorporate new texts so perhaps this isn’t an issue, but just something we will have to bear in mind.  I’ll continue with this next week.

I also updated the entry page to make language tags searchable.  You can now click on language tags (for example in this page https://anglo-norman.net/entry/alabrot) and perform a search for the corresponding language.